terminal/src/cascadia/TerminalSettingsModel/GlobalAppSettings.idl
Mike Griese 6639df9edc
Allow the user to use the tab switcher with in-order tab switching (#8076)
## Summary of the Pull Request

Changes the way the `useTabSwitcher` setting works. It now accepts either a boolean or a string:
* `true`, `"mru"`: Use the tab switcher with MRU tab switching
* `"inOrder"`: Use the tab switcher, with in-order tab switching
* `false`, `"disabled"`: Don't use the tab switcher. Tabs will switch in-order.

This is following the discussion chronicled in #8025, as well as the follow-up investigation in that thread.

## References

* #7952 introduced MRU tab switching

## PR Checklist
* [x] Closes #8025 - there's also discussion of using a parameter in an action to override this setting, but that should get punted to a follow-up task
* [x] I work here
* [x] Tests added/passed - YOU BET THEY WERE
* [ ] Requires documentation to be updated

## Validation Steps Performed

I've been switching tabs all day and all night, with different settings values, and hot-reloading the setting.

I also _ran the test_ I added.
2020-11-05 14:28:16 +00:00

146 lines
4.1 KiB
Plaintext

// Copyright (c) Microsoft Corporation.
// Licensed under the MIT license.
import "ColorScheme.idl";
import "KeyMapping.idl";
import "Command.idl";
namespace Microsoft.Terminal.Settings.Model
{
// MIDL 3 allows for structs to hold nullable types
// Though IReference is a WinRT object, MIDL 3
// handles all of the ownership logic for us.
// Docs: https://docs.microsoft.com/en-us/uwp/midl-3/intro#types
struct LaunchPosition
{
Windows.Foundation.IReference<Int64> X;
Windows.Foundation.IReference<Int64> Y;
};
enum LaunchMode
{
DefaultMode,
MaximizedMode,
FullscreenMode,
FocusMode,
MaximizedFocusMode,
};
enum TabSwitcherMode
{
MostRecentlyUsed,
InOrder,
Disabled,
};
[default_interface] runtimeclass GlobalAppSettings {
Guid DefaultProfile;
Boolean HasUnparsedDefaultProfile();
void ClearUnparsedDefaultProfile();
String UnparsedDefaultProfile;
Boolean HasInitialRows();
void ClearInitialRows();
Int32 InitialRows;
Boolean HasInitialCols();
void ClearInitialCols();
Int32 InitialCols;
Boolean HasAlwaysShowTabs();
void ClearAlwaysShowTabs();
Boolean AlwaysShowTabs;
Boolean HasShowTitleInTitlebar();
void ClearShowTitleInTitlebar();
Boolean ShowTitleInTitlebar;
Boolean HasConfirmCloseAllTabs();
void ClearConfirmCloseAllTabs();
Boolean ConfirmCloseAllTabs;
Boolean HasTheme();
void ClearTheme();
Windows.UI.Xaml.ElementTheme Theme;
Boolean HasTabWidthMode();
void ClearTabWidthMode();
Microsoft.UI.Xaml.Controls.TabViewWidthMode TabWidthMode;
Boolean HasShowTabsInTitlebar();
void ClearShowTabsInTitlebar();
Boolean ShowTabsInTitlebar;
Boolean HasWordDelimiters();
void ClearWordDelimiters();
String WordDelimiters;
Boolean HasCopyOnSelect();
void ClearCopyOnSelect();
Boolean CopyOnSelect;
Boolean HasCopyFormatting();
void ClearCopyFormatting();
Microsoft.Terminal.TerminalControl.CopyFormat CopyFormatting;
Boolean HasWarnAboutLargePaste();
void ClearWarnAboutLargePaste();
Boolean WarnAboutLargePaste;
Boolean HasWarnAboutMultiLinePaste();
void ClearWarnAboutMultiLinePaste();
Boolean WarnAboutMultiLinePaste;
Boolean HasInitialPosition();
void ClearInitialPosition();
LaunchPosition InitialPosition;
Boolean HasLaunchMode();
void ClearLaunchMode();
LaunchMode LaunchMode;
Boolean HasSnapToGridOnResize();
void ClearSnapToGridOnResize();
Boolean SnapToGridOnResize;
Boolean HasForceFullRepaintRendering();
void ClearForceFullRepaintRendering();
Boolean ForceFullRepaintRendering;
Boolean HasSoftwareRendering();
void ClearSoftwareRendering();
Boolean SoftwareRendering;
Boolean HasForceVTInput();
void ClearForceVTInput();
Boolean ForceVTInput;
Boolean HasDebugFeaturesEnabled();
void ClearDebugFeaturesEnabled();
Boolean DebugFeaturesEnabled;
Boolean HasStartOnUserLogin();
void ClearStartOnUserLogin();
Boolean StartOnUserLogin;
Boolean HasAlwaysOnTop();
void ClearAlwaysOnTop();
Boolean AlwaysOnTop;
Boolean HasTabSwitcherMode();
void ClearTabSwitcherMode();
TabSwitcherMode TabSwitcherMode;
Boolean HasDisableAnimations();
void ClearDisableAnimations();
Boolean DisableAnimations;
Windows.Foundation.Collections.IMapView<String, ColorScheme> ColorSchemes();
void AddColorScheme(ColorScheme scheme);
KeyMapping KeyMap();
Windows.Foundation.Collections.IMapView<String, Command> Commands();
}
}