all repos — fluxbox @ 76a38e466c84e2129794068d3196b0d1e61a2b4f

custom fork of the fluxbox windowmanager

indentation and the frame.handle destroy
fluxgen fluxgen
commit

76a38e466c84e2129794068d3196b0d1e61a2b4f

parent

2652479b7cdf86a92617ef03f5bee0fc513f037b

1 files changed, 26 insertions(+), 20 deletions(-)

jump to
M src/Window.ccsrc/Window.cc

@@ -22,7 +22,7 @@ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING

// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: Window.cc,v 1.22 2002/01/20 02:14:20 fluxgen Exp $ +// $Id: Window.cc,v 1.23 2002/01/27 13:13:33 fluxgen Exp $ // stupid macros needed to access some functions in version 2 of the GNU C // library

@@ -458,11 +458,11 @@ if (client.transient)

client.transient->client.transient_for = client.transient_for; while ( !buttonlist.empty()) { //destroy all buttons on titlebar - fluxbox->removeWindowSearch(buttonlist.back().win); + fluxbox->removeWindowSearch(buttonlist.back().win); XDestroyWindow(display, buttonlist.back().win); buttonlist.pop_back(); } - + if (frame.title) { if (frame.ftitle) image_ctrl->removeImage(frame.ftitle);

@@ -495,12 +495,13 @@

if (frame.ugrip) image_ctrl->removeImage(frame.ugrip); - fluxbox->removeWindowSearch(frame.handle); fluxbox->removeWindowSearch(frame.right_grip); fluxbox->removeWindowSearch(frame.left_grip); - XDestroyWindow(display, frame.handle); + fluxbox->removeWindowSearch(frame.handle); + XDestroyWindow(display, frame.right_grip); - XDestroyWindow(display, frame.left_grip); + XDestroyWindow(display, frame.left_grip); + XDestroyWindow(display, frame.handle); } if (frame.fbutton)

@@ -528,8 +529,9 @@ fluxbox->removeWindowSearch(client.window);

screen->removeNetizen(client.window); } - #ifdef DEBUG - fprintf(stderr, "%s(%d): ~FluxboxWindow(this=%p) done\n", __FILE__, __LINE__, this); + + #ifdef DEBUG + cerr<<__FILE__<<"("<<__LINE__<<"): ~FluxboxWindow(this="<<this<<") done"<<endl; #endif }

@@ -811,11 +813,11 @@ image_ctrl->renderImage(frame.grip_w, frame.grip_h, texture);

if (tmp) image_ctrl->removeImage(tmp); XSetWindowBorder(display, frame.handle, - screen->getBorderColor()->getPixel()); + screen->getBorderColor()->getPixel()); XSetWindowBorder(display, frame.left_grip, - screen->getBorderColor()->getPixel()); + screen->getBorderColor()->getPixel()); XSetWindowBorder(display, frame.right_grip, - screen->getBorderColor()->getPixel()); + screen->getBorderColor()->getPixel()); } XSetWindowBorder(display, frame.window,

@@ -1163,13 +1165,13 @@ XSetWindowBorderWidth(display, frame.left_grip, screen->getBorderWidth());

XSetWindowBorderWidth(display, frame.right_grip, screen->getBorderWidth()); XMoveResizeWindow(display, frame.handle, -screen->getBorderWidth(), - frame.y_handle - screen->getBorderWidth(), - frame.width, frame.handle_h); + frame.y_handle - screen->getBorderWidth(), + frame.width, frame.handle_h); XMoveResizeWindow(display, frame.left_grip, -screen->getBorderWidth(), - -screen->getBorderWidth(), frame.grip_w, frame.grip_h); + -screen->getBorderWidth(), frame.grip_w, frame.grip_h); XMoveResizeWindow(display, frame.right_grip, - frame.width - frame.grip_w - screen->getBorderWidth(), - -screen->getBorderWidth(), frame.grip_w, frame.grip_h); + frame.width - frame.grip_w - screen->getBorderWidth(), + -screen->getBorderWidth(), frame.grip_w, frame.grip_h); XMapSubwindows(display, frame.handle); } else if (frame.handle) XUnmapWindow(display, frame.handle);

@@ -1757,7 +1759,7 @@

XSelectInput(display, client.window, NoEventMask); XMapWindow(display, client.window); XSelectInput(display, client.window, - PropertyChangeMask | StructureNotifyMask | FocusChangeMask); + PropertyChangeMask | StructureNotifyMask | FocusChangeMask); XMapSubwindows(display, frame.window); XMapWindow(display, frame.window);

@@ -2582,7 +2584,11 @@ delete this;

} } - +//----------- destroyNotifyEvent ------------- +// Checks if event is for client.window. +// Unmaps frame.window and returns true for destroy +// of this FluxboxWindow else returns false. +//-------------------------------------------- bool FluxboxWindow::destroyNotifyEvent(XDestroyWindowEvent *de) { if (de->window == client.window) { #ifdef DEBUG

@@ -3080,8 +3086,8 @@ screen->showPosition(dx, dy);

} } else if (functions.resize && (((me->state & Button1Mask) && (me->window == frame.right_grip || - me->window == frame.left_grip)) || - me->window == frame.window)) { + me->window == frame.left_grip)) || + me->window == frame.window)) { bool left = (me->window == frame.left_grip); if (! resizing) {