* Archive/Unarchive refresh interval

* Minor style fix


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29976 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Alexandre Deckner
2009-04-06 20:30:21 +00:00
parent 49950a1598
commit eee6f40b8b
+8 -1
View File
@@ -600,13 +600,16 @@ ActivityView::_Init(const BMessage* settings)
#endif #endif
SetViewColor(B_TRANSPARENT_COLOR); SetViewColor(B_TRANSPARENT_COLOR);
fRefreshInterval = kInitialRefreshInterval;
fLastRefresh = 0; fLastRefresh = 0;
fDrawResolution = 1; fDrawResolution = 1;
fZooming = false; fZooming = false;
fSystemInfoHandler = new SystemInfoHandler; fSystemInfoHandler = new SystemInfoHandler;
if (settings == NULL
|| settings->FindInt64("refresh interval", &fRefreshInterval) != B_OK)
fRefreshInterval = kInitialRefreshInterval;
if (settings == NULL if (settings == NULL
|| settings->FindBool("show legend", &fShowLegend) != B_OK) || settings->FindBool("show legend", &fShowLegend) != B_OK)
fShowLegend = true; fShowLegend = true;
@@ -666,6 +669,10 @@ ActivityView::SaveState(BMessage& state) const
if (status != B_OK) if (status != B_OK)
return status; return status;
status = state.AddInt64("refresh interval", fRefreshInterval);
if (status != B_OK)
return status;
status = state.AddData("history background color", B_RGB_COLOR_TYPE, status = state.AddData("history background color", B_RGB_COLOR_TYPE,
&fHistoryBackgroundColor, sizeof(rgb_color)); &fHistoryBackgroundColor, sizeof(rgb_color));
if (status != B_OK) if (status != B_OK)