summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam Spilsbury <smspillaz@XPS-FEDORA.(none)>2010-04-29 10:18:54 +0800
committerSam Spilsbury <smspillaz@XPS-FEDORA.(none)>2010-04-29 10:18:54 +0800
commit2ad9cc87c63d74cd869c96a9406236d164cd607b (patch)
tree4552e915660acee1e5711029764f8f612f0751d5
parenta0d7e05f43faff16c8f4d85a099540b934f654b1 (diff)
downloadstackswitch-2ad9cc87c63d74cd869c96a9406236d164cd607b.tar.gz
stackswitch-2ad9cc87c63d74cd869c96a9406236d164cd607b.tar.bz2
Fix incorrect indentation
-rw-r--r--src/stackswitch.cpp112
1 files changed, 56 insertions, 56 deletions
diff --git a/src/stackswitch.cpp b/src/stackswitch.cpp
index 4715839..7ce59a9 100644
--- a/src/stackswitch.cpp
+++ b/src/stackswitch.cpp
@@ -1015,39 +1015,39 @@ StackswitchScreen::terminate (CompAction *action,
CompAction::State state,
CompOption::Vector options)
{
- if (mGrabIndex)
- {
- screen->removeGrab (mGrabIndex, 0);
- mGrabIndex = 0;
- }
-
- if (mState != StackswitchStateNone)
- {
- CompWindow *w;
+ if (mGrabIndex)
+ {
+ screen->removeGrab (mGrabIndex, 0);
+ mGrabIndex = 0;
+ }
- foreach (CompWindow *w, screen->windows ())
- {
- STACKSWITCH_WINDOW (w);
-
- if (sw->mSlot)
- {
- free (sw->mSlot);
- sw->mSlot = NULL;
+ if (mState != StackswitchStateNone)
+ {
+ CompWindow *w;
- sw->mAdjust = true;
- }
- }
- mMoreAdjust = true;
- mState = StackswitchStateIn;
- cScreen->damageScreen ();
+ foreach (CompWindow *w, screen->windows ())
+ {
+ STACKSWITCH_WINDOW (w);
- if (!(state & CompAction::StateCancel) && mSelectedWindow)
+ if (sw->mSlot)
{
- w = screen->findWindow (mSelectedWindow);
- if (w)
- screen->sendWindowActivationRequest (w->id ());
+ free (sw->mSlot);
+ sw->mSlot = NULL;
+
+ sw->mAdjust = true;
}
- }
+ }
+ mMoreAdjust = true;
+ mState = StackswitchStateIn;
+ cScreen->damageScreen ();
+
+ if (!(state & CompAction::StateCancel) && mSelectedWindow)
+ {
+ w = screen->findWindow (mSelectedWindow);
+ if (w)
+ screen->sendWindowActivationRequest (w->id ());
+ }
+ }
if (action)
action->setState (action->state () & ~(CompAction::StateTermKey |
@@ -1121,37 +1121,37 @@ StackswitchScreen::doSwitch (CompAction *action,
{
bool ret = true;
- if ((mState == StackswitchStateNone) || (mState == StackswitchStateIn))
- {
- if (mType == StackswitchTypeGroup)
- {
- CompWindow *w;
- w = screen->findWindow (CompOption::getIntOptionNamed (options, "window", 0));
- if (w)
- {
- mType = StackswitchTypeGroup;
- mClientLeader =
- (w->clientLeader ()) ? w->clientLeader () : w->id ();
- ret = initiate (action, state, options);
- }
- }
- else
+ if ((mState == StackswitchStateNone) || (mState == StackswitchStateIn))
+ {
+ if (mType == StackswitchTypeGroup)
+ {
+ CompWindow *w;
+ w = screen->findWindow (CompOption::getIntOptionNamed (options, "window", 0));
+ if (w)
{
- mType = type;
- ret = initiate (action, state, options);
+ mType = StackswitchTypeGroup;
+ mClientLeader =
+ (w->clientLeader ()) ? w->clientLeader () : w->id ();
+ ret = initiate (action, state, options);
}
+ }
+ else
+ {
+ mType = type;
+ ret = initiate (action, state, options);
+ }
+
+ if (state & CompAction::StateInitKey)
+ action->setState (action->state () | CompAction::StateTermKey);
+
+ if (state & CompAction::StateInitEdge)
+ action->setState (action->state () | CompAction::StateTermEdge);
+ else if (state & CompAction::StateInitButton)
+ action->setState (action->state () | CompAction::StateTermButton);
+ }
- if (state & CompAction::StateInitKey)
- action->setState (action->state () | CompAction::StateTermKey);
-
- if (state & CompAction::StateInitEdge)
- action->setState (action->state () | CompAction::StateTermEdge);
- else if (state & CompAction::StateInitButton)
- action->setState (action->state () | CompAction::StateTermButton);
- }
-
- if (ret)
- switchToWindow (nextWindow);
+ if (ret)
+ switchToWindow (nextWindow);
return ret;
}