From 0f1dd8e8b582f03ec0125e0ea237a3f9cbeabd86 Mon Sep 17 00:00:00 2001 From: fluxgen Date: Thu, 2 May 2002 07:09:22 +0000 Subject: added moveNext/movePrev --- src/Tab.cc | 17 ++++++++++++++++- src/Tab.hh | 6 ++++-- 2 files changed, 20 insertions(+), 3 deletions(-) diff --git a/src/Tab.cc b/src/Tab.cc index 45346c4..e89a3bd 100644 --- a/src/Tab.cc +++ b/src/Tab.cc @@ -19,7 +19,7 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: Tab.cc,v 1.25 2002/04/28 08:49:31 fluxgen Exp $ +// $Id: Tab.cc,v 1.26 2002/05/02 07:09:22 fluxgen Exp $ #include "Tab.hh" @@ -537,6 +537,21 @@ void Tab::setPosition() { m_stoptabs = false;//thaw tablist } +//Moves the tab to the left +void Tab::movePrev() { + insert(m_prev); +} + +//Moves the tab to the next tab if m_next != 0 +void Tab::moveNext() { + if(m_next == 0) + return; + Tab *tmp = m_next; + disconnect(); + tmp->insert(this); +} + + //------------- calcIncrease ---------------- // calculates m_inc_x and m_inc_y for tabs // used for positioning the tabs. diff --git a/src/Tab.hh b/src/Tab.hh index d23255a..22d0980 100644 --- a/src/Tab.hh +++ b/src/Tab.hh @@ -19,7 +19,7 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: Tab.hh,v 1.11 2002/02/17 18:52:02 fluxgen Exp $ +// $Id: Tab.hh,v 1.12 2002/05/02 07:08:24 fluxgen Exp $ #ifndef TAB_HH #define TAB_HH @@ -63,6 +63,8 @@ public: void shade(); //position tab to follow (FluxboxWindow *) m_win void setPosition(); + void moveNext(); + void movePrev(); //event handlers void buttonReleaseEvent(XButtonEvent *be); void buttonPressEvent(XButtonEvent *be); @@ -76,7 +78,7 @@ public: static Tab::Placement getTabPlacementNum(const char *string); static const char *getTabAlignmentString(Tab::Alignment alignment); static Tab::Alignment getTabAlignmentNum(const char *string); - //TODO: do these have to be public? + void resizeGroup(void); // used when (un)shading windows void calcIncrease(void); inline bool configured() { return m_configured; } -- cgit v0.11.2