X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;f=src%2Fframe.hh;h=45916a1d9a3b1391bc02b92a15eaff947d2f85f4;hb=7fe3301e7ea905a8a76d54c22751f3d8a346e28b;hp=c75194c44cd136333a2bb10728ae070646bb419c;hpb=c88451f0c1e2586a5a06babb69b060bf808c9148;p=chaz%2Fopenbox diff --git a/src/frame.hh b/src/frame.hh index c75194c4..45916a1d 100644 --- a/src/frame.hh +++ b/src/frame.hh @@ -9,6 +9,7 @@ extern "C" { #include } +#include "client.hh" #include "python.hh" #include "otk/strut.hh" #include "otk/rect.hh" @@ -22,8 +23,6 @@ extern "C" { namespace ob { -class Client; - //! Varius geometry settings in the frame decorations struct FrameGeometry { int width; // title and handle @@ -66,6 +65,9 @@ private: otk::Rect _area; bool _visible; + + //! The decorations that are being displayed in the frame. + Client::DecorationFlags _decorations; // decoration windows Window _frame; // sits under everything @@ -93,12 +95,14 @@ private: otk::Surface *_icon_sur; otk::Surface *_close_sur; - std::string _layout; // layout of the titlebar + otk::ustring _layout; // layout of the titlebar + bool _max_press; bool _desk_press; bool _iconify_press; bool _icon_press; bool _close_press; + unsigned int _press_button; // mouse button that started the press FrameGeometry geom; @@ -142,6 +146,7 @@ public: void adjustState(); void adjustFocus(); void adjustTitle(); + void adjustIcon(); //! Applies gravity to the client's position to find where the frame should //! be positioned. @@ -168,6 +173,9 @@ public: //! Hides the frame void hide(); + void buttonPressHandler(const XButtonEvent &e); + void buttonReleaseHandler(const XButtonEvent &e); + //! Returns the MouseContext for the given window id /*! Returns '-1' if no valid mouse context exists in the frame for the given