- Automatic whitespace cleanup.
- Remove no longer exposed show/hide time setting. The methodology for
  saving it on exit was broken anyways, since it relied on the current
  show/hide state of the time view, which would be hidden if the deskbar
  was currently in Autohide mode.
This commit is contained in:
Rene Gollent
2012-06-16 16:45:28 -04:00
parent 919d3b7601
commit a663e90506
3 changed files with 8 additions and 21 deletions
-6
View File
@@ -204,7 +204,6 @@ TBarApp::SaveSettings()
storedSettings.AddInt32("state", fSettings.state); storedSettings.AddInt32("state", fSettings.state);
storedSettings.AddFloat("width", fSettings.width); storedSettings.AddFloat("width", fSettings.width);
storedSettings.AddBool("showTime", fSettings.showTime);
storedSettings.AddBool("showSeconds", fSettings.showSeconds); storedSettings.AddBool("showSeconds", fSettings.showSeconds);
storedSettings.AddBool("showDayOfWeek", fSettings.showDayOfWeek); storedSettings.AddBool("showDayOfWeek", fSettings.showDayOfWeek);
@@ -244,7 +243,6 @@ TBarApp::InitSettings()
settings.vertical = true; settings.vertical = true;
settings.left = false; settings.left = false;
settings.top = true; settings.top = true;
settings.showTime = true;
settings.showSeconds = false; settings.showSeconds = false;
settings.showDayOfWeek = false; settings.showDayOfWeek = false;
settings.state = kExpandoState; settings.state = kExpandoState;
@@ -301,10 +299,6 @@ TBarApp::InitSettings()
} }
if (storedSettings.FindFloat("width", &settings.width) != B_OK) if (storedSettings.FindFloat("width", &settings.width) != B_OK)
settings.width = 0; settings.width = 0;
if (storedSettings.FindBool("showTime", &settings.showTime)
!= B_OK) {
settings.showTime = true;
}
if (storedSettings.FindBool("showSeconds", &settings.showSeconds) if (storedSettings.FindBool("showSeconds", &settings.showSeconds)
!= B_OK) { != B_OK) {
settings.showSeconds = false; settings.showSeconds = false;
-1
View File
@@ -75,7 +75,6 @@ struct desk_settings {
bool vertical; bool vertical;
bool left; bool left;
bool top; bool top;
bool showTime;
bool showSeconds; bool showSeconds;
bool showDayOfWeek; bool showDayOfWeek;
uint32 state; uint32 state;
-6
View File
@@ -181,11 +181,6 @@ TReplicantTray::AttachedToWindow()
AddChild(fTime); AddChild(fTime);
fTime->MoveTo(Bounds().right - fTime->Bounds().Width() - 1, 2); fTime->MoveTo(Bounds().right - fTime->Bounds().Width() - 1, 2);
if (!((TBarApp*)be_app)->Settings()->showTime) {
fTime->Hide();
RealignReplicants();
AdjustPlacement();
}
#ifdef DB_ADDONS #ifdef DB_ADDONS
// load addons and rehydrate archives // load addons and rehydrate archives
@@ -1240,7 +1235,6 @@ TReplicantTray::SaveTimeSettings()
return; return;
desk_settings* settings = ((TBarApp*)be_app)->Settings(); desk_settings* settings = ((TBarApp*)be_app)->Settings();
settings->showTime = !fTime->IsHidden();
settings->showSeconds = fTime->ShowSeconds(); settings->showSeconds = fTime->ShowSeconds();
settings->showDayOfWeek = fTime->ShowDayOfWeek(); settings->showDayOfWeek = fTime->ShowDayOfWeek();
} }