mirror of
https://github.com/aseprite/aseprite.git
synced 2025-01-01 09:04:02 +00:00
Add option to disable Home tab (fix #1368)
This commit is contained in:
parent
f8874f4f7b
commit
7ae63156c5
@ -95,6 +95,7 @@
|
||||
<option id="screen_scale" type="int" default="0" />
|
||||
<option id="ui_scale" type="int" default="1" migrate="experimental.ui_scale" />
|
||||
<option id="gpu_acceleration" type="bool" default="false" />
|
||||
<option id="show_home" type="bool" default="true" />
|
||||
<option id="visible_timeline" type="bool" default="false" />
|
||||
<option id="autoshow_timeline" type="bool" default="true" migrate="Options.AutoShowTimeline" />
|
||||
<option id="rewind_on_stop" type="bool" default="false" />
|
||||
|
@ -40,6 +40,7 @@
|
||||
</grid>
|
||||
</hbox>
|
||||
<check text="GPU acceleration" id="gpu_acceleration" tooltip="Check this option to enable hardware acceleration" />
|
||||
<check text="Show Home tab when Aseprite is started" id="show_home" />
|
||||
<check text="Expand menu bar items on mouseover" id="expand_menubar_on_mouseover" tooltip="Check this option to get this old menus behavior." />
|
||||
<hbox>
|
||||
<check text="Automatically save recovery data every" id="enable_data_recovery" tooltip="With this option you can recover your documents if the program finalizes unexpectedly." />
|
||||
|
@ -194,6 +194,8 @@ public:
|
||||
gpuAcceleration()->setVisible(false);
|
||||
}
|
||||
|
||||
showHome()->setSelected(m_pref.general.showHome());
|
||||
|
||||
// Right-click
|
||||
|
||||
static_assert(int(app::gen::RightClickMode::PAINT_BGCOLOR) == 0, "");
|
||||
@ -353,6 +355,10 @@ public:
|
||||
reset_screen = true;
|
||||
}
|
||||
|
||||
bool newShowHome = showHome()->isSelected();
|
||||
if (newShowHome != m_pref.general.showHome())
|
||||
m_pref.general.showHome(newShowHome);
|
||||
|
||||
m_pref.save();
|
||||
|
||||
if (!warnings.empty()) {
|
||||
|
@ -229,6 +229,12 @@ void MainWindow::showNotification(INotificationDelegate* del)
|
||||
|
||||
void MainWindow::showHomeOnOpen()
|
||||
{
|
||||
// Don't open Home tab
|
||||
if (!Preferences::instance().general.showHome()) {
|
||||
configureWorkspaceLayout();
|
||||
return;
|
||||
}
|
||||
|
||||
if (!getHomeView()->parent()) {
|
||||
TabView* selectedTab = m_tabsBar->getSelectedTab();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user