Skip to content

Instantly share code, notes, and snippets.

@LewisW
Created April 5, 2012 12:51
Show Gist options
  • Save LewisW/2310841 to your computer and use it in GitHub Desktop.
Save LewisW/2310841 to your computer and use it in GitHub Desktop.
Moves to the next tab group in PHPEdit
$groups = P::$UserInterface->DocumentWindows->Pane1Groups;
$i = 0;
$found_group = false;
// Loop through each group
foreach ($groups as $group) {
if ($group->Windows->IndexOf(P::$UserInterface->DocumentWindows->ActiveWindow) > -1) {
$found_group = $i;
}
++$i;
}
$first_group = $groups->get_Item((++$found_group < $groups->Count) ? $found_group : 0);
$first_group->Windows->get_Item(0)->activate();
P::$UserInterface->StatusBar->UpdateStatusMessage(VerboseEngineMessageType::Hint, "Changed to group: ". $first_group->GroupInfo->Text);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment