Use -Wall when --enable-debug and some warning fixes
+ thanks Jonas Koelker
This commit is contained in:
parent
f6a072430d
commit
acf4326f3c
10 changed files with 20 additions and 11 deletions
|
@ -1,6 +1,11 @@
|
|||
(Format: Year/Month/Day)
|
||||
Changes for 0.9.16:
|
||||
*06/04/24:
|
||||
* Use -Wall when --enable-debug and some warning fixes
|
||||
(Simon + thanks Jonas Koelker)
|
||||
configure.in ClockTool.cc main.cc Ewmh.cc Window.cc
|
||||
PlacementStrategy.hh LayerMenu.hh FbTk/SignalHandler.hh
|
||||
FbTk/FbWindow.hh
|
||||
* Fix memory leaks & other errors in Menu code (Simon)
|
||||
Screen.cc Slit.cc Toolbar.cc fluxbox.cc MenuCreator.cc FbTk/Menu.cc
|
||||
* Use external tabs by default (Simon)
|
||||
|
|
|
@ -320,7 +320,7 @@ AC_ARG_ENABLE(debug,
|
|||
[ --enable-debug include verbose debugging code [default=no]],
|
||||
if test x$enableval = "xyes"; then
|
||||
AC_MSG_RESULT([yes])
|
||||
DEBUG="-DDEBUG"
|
||||
DEBUG="-DDEBUG -Wall"
|
||||
else
|
||||
AC_MSG_RESULT([no])
|
||||
fi,
|
||||
|
|
|
@ -257,7 +257,7 @@ void ClockTool::updateTime() {
|
|||
return;
|
||||
m_button.setText(time_string);
|
||||
|
||||
int new_width = m_theme.font().textWidth(time_string, time_string_len) + 2;
|
||||
unsigned int new_width = m_theme.font().textWidth(time_string, time_string_len) + 2;
|
||||
if (new_width > m_button.width()) {
|
||||
resize(new_width, m_button.height());
|
||||
resizeSig().notify();
|
||||
|
|
|
@ -267,8 +267,8 @@ void Ewmh::setupFrame(FluxboxWindow &win) {
|
|||
if (win.winClient().property(m_net_wm_desktop, 0, 1, False, XA_CARDINAL,
|
||||
&ret_type, &fmt, &nitems, &bytes_after,
|
||||
(unsigned char **) &data) && data) {
|
||||
unsigned int desktop = static_cast<unsigned int>(*data);
|
||||
if (desktop == 0xFFFFFFFF && !win.isStuck())
|
||||
unsigned int desktop = static_cast<long>(*data);
|
||||
if (desktop == -1 && !win.isStuck())
|
||||
win.stick();
|
||||
else
|
||||
win.setWorkspace(desktop);
|
||||
|
@ -634,7 +634,7 @@ void Ewmh::updateWorkspace(FluxboxWindow &win) {
|
|||
long workspace = win.isInitialized() ? win.workspaceNumber() : win.screen().currentWorkspaceID();
|
||||
|
||||
if (win.isStuck())
|
||||
workspace = 0xFFFFFFFF; // appear on all desktops/workspaces
|
||||
workspace = -1; // appear on all desktops/workspaces
|
||||
|
||||
FluxboxWindow::ClientList::iterator it = win.clientList().begin();
|
||||
FluxboxWindow::ClientList::iterator it_end = win.clientList().end();
|
||||
|
@ -661,7 +661,7 @@ bool Ewmh::checkClientMessage(const XClientMessageEvent &ce,
|
|||
|
||||
// if it's stick, make sure it is stuck.
|
||||
// otherwise, make sure it isn't stuck
|
||||
if (ce.data.l[0] == 0xFFFFFFFF) {
|
||||
if (ce.data.l[0] == -1) {
|
||||
if (!fbwin->isStuck())
|
||||
fbwin->stick();
|
||||
return true;
|
||||
|
|
|
@ -266,6 +266,7 @@ private:
|
|||
class FbWindowRenderer {
|
||||
public:
|
||||
virtual void renderForeground(FbWindow &win, FbDrawable &drawable) = 0;
|
||||
virtual ~FbWindowRenderer() { }
|
||||
};
|
||||
|
||||
|
||||
|
|
|
@ -33,6 +33,7 @@ namespace FbTk {
|
|||
class SignalEventHandler {
|
||||
public:
|
||||
virtual void handleSignal(int signum) = 0;
|
||||
virtual ~SignalEventHandler() { }
|
||||
};
|
||||
|
||||
/// Handles system signals, singleton.
|
||||
|
|
|
@ -34,6 +34,7 @@ class LayerObject {
|
|||
public:
|
||||
virtual void moveToLayer(int layer_number) = 0;
|
||||
virtual int layerNumber() const = 0;
|
||||
virtual ~LayerObject() { }
|
||||
};
|
||||
|
||||
|
||||
|
|
|
@ -40,6 +40,7 @@ struct PlacementStrategy {
|
|||
virtual bool placeWindow(const std::vector<FluxboxWindow *> &windowlist,
|
||||
const FluxboxWindow &win,
|
||||
int &place_x, int &place_y) = 0;
|
||||
virtual ~PlacementStrategy() { }
|
||||
};
|
||||
|
||||
#endif // PLACEMENTSTRATEGY_HH
|
||||
|
|
|
@ -3378,7 +3378,7 @@ void FluxboxWindow::doSnapping(int &orig_left, int &orig_top) {
|
|||
|
||||
// test against tabs too
|
||||
bool i_have_tabs = frame().externalTabMode();
|
||||
int xoff,yoff,woff,hoff;
|
||||
int xoff = 0, yoff = 0, woff = 0, hoff = 0;
|
||||
if (i_have_tabs) {
|
||||
xoff = xOffset();
|
||||
yoff = yOffset();
|
||||
|
@ -3386,7 +3386,6 @@ void FluxboxWindow::doSnapping(int &orig_left, int &orig_top) {
|
|||
hoff = heightOffset();
|
||||
}
|
||||
|
||||
|
||||
/////////////////////////////////////
|
||||
// begin by checking the screen (or Xinerama head) edges
|
||||
|
||||
|
|
|
@ -304,9 +304,10 @@ int main(int argc, char **argv) {
|
|||
cerr.rdbuf(errbuf);
|
||||
|
||||
if (restarting) {
|
||||
if (restart_argument.c_str()) {
|
||||
execlp(restart_argument.c_str(), restart_argument.c_str(), 0);
|
||||
perror(restart_argument.c_str());
|
||||
const char *arg = restart_argument.c_str();
|
||||
if (arg) {
|
||||
execlp(arg, arg, (char *) NULL);
|
||||
perror(arg);
|
||||
}
|
||||
|
||||
// fall back in case the above execlp doesn't work
|
||||
|
|
Loading…
Reference in a new issue