diff options
author | Pavel Labath <pavelo@centrum.sk> | 2011-06-16 19:09:37 (GMT) |
---|---|---|
committer | Pavel Labath <pavelo@centrum.sk> | 2013-02-16 23:54:31 (GMT) |
commit | 9f2c3883b7cf08a5f9d311fd8f7fc317574b605b (patch) | |
tree | 55461e357b95ddaa582b73c840f4c5e6846b0f69 /src/Toolbar.cc | |
parent | 590efd07bb2ed1ce78ce6e5e6750b57311904f1f (diff) | |
download | fluxbox_pavel-9f2c3883b7cf08a5f9d311fd8f7fc317574b605b.zip fluxbox_pavel-9f2c3883b7cf08a5f9d311fd8f7fc317574b605b.tar.bz2 |
Replace ResourceManager with the lua version
Loading of an init file with the new manager works ok. Saving and restarting is still not
completed.
This touches many files because i removed the alternative name of resources. Unlike Xrm, lua does
not have native support for alt names. It should be fairly easy to add them, but I think that is
unnecessary and would be confusing.
Diffstat (limited to 'src/Toolbar.cc')
-rw-r--r-- | src/Toolbar.cc | 28 |
1 files changed, 10 insertions, 18 deletions
diff --git a/src/Toolbar.cc b/src/Toolbar.cc index cb1ee60..4490a4b 100644 --- a/src/Toolbar.cc +++ b/src/Toolbar.cc | |||
@@ -173,25 +173,18 @@ Toolbar::Toolbar(BScreen &scrn, FbTk::Layer &layer, size_t width): | |||
173 | m_theme(scrn.screenNumber()), | 173 | m_theme(scrn.screenNumber()), |
174 | m_tool_factory(scrn), | 174 | m_tool_factory(scrn), |
175 | m_strut(0), | 175 | m_strut(0), |
176 | // lock rcmanager here | 176 | m_rc_auto_hide(scrn.resourceManager(), false, scrn.name() + ".toolbar.autoHide"), |
177 | m_rc_auto_hide(scrn.resourceManager().lock(), false, | 177 | m_rc_maximize_over(scrn.resourceManager(), false, scrn.name() + ".toolbar.maxOver"), |
178 | scrn.name() + ".toolbar.autoHide", scrn.altName() + ".Toolbar.AutoHide"), | 178 | m_rc_visible(scrn.resourceManager(), true, scrn.name() + ".toolbar.visible"), |
179 | m_rc_maximize_over(scrn.resourceManager(), false, | 179 | m_rc_width_percent(scrn.resourceManager(), 100, scrn.name() + ".toolbar.widthPercent"), |
180 | scrn.name() + ".toolbar.maxOver", scrn.altName() + ".Toolbar.MaxOver"), | 180 | m_rc_alpha(scrn.resourceManager(), 255, scrn.name() + ".toolbar.alpha"), |
181 | m_rc_visible(scrn.resourceManager(), true, scrn.name() + ".toolbar.visible", scrn.altName() + ".Toolbar.Visible"), | 181 | m_rc_layernum(scrn.resourceManager(), ResourceLayer::DOCK, scrn.name() + ".toolbar.layer"), |
182 | m_rc_width_percent(scrn.resourceManager(), 100, | 182 | m_rc_on_head(scrn.resourceManager(), 1, scrn.name() + ".toolbar.onhead"), |
183 | scrn.name() + ".toolbar.widthPercent", scrn.altName() + ".Toolbar.WidthPercent"), | ||
184 | m_rc_alpha(scrn.resourceManager(), 255, | ||
185 | scrn.name() + ".toolbar.alpha", scrn.altName() + ".Toolbar.Alpha"), | ||
186 | m_rc_layernum(scrn.resourceManager(), ResourceLayer::DOCK, | ||
187 | scrn.name() + ".toolbar.layer", scrn.altName() + ".Toolbar.Layer"), | ||
188 | m_rc_on_head(scrn.resourceManager(), 1, | ||
189 | scrn.name() + ".toolbar.onhead", scrn.altName() + ".Toolbar.onHead"), | ||
190 | m_rc_placement(scrn.resourceManager(), Toolbar::BOTTOMCENTER, | 183 | m_rc_placement(scrn.resourceManager(), Toolbar::BOTTOMCENTER, |
191 | scrn.name() + ".toolbar.placement", scrn.altName() + ".Toolbar.Placement"), | 184 | scrn.name() + ".toolbar.placement"), |
192 | m_rc_height(scrn.resourceManager(), 0, scrn.name() + ".toolbar.height", scrn.altName() + ".Toolbar.Height"), | 185 | m_rc_height(scrn.resourceManager(), 0, scrn.name() + ".toolbar.height"), |
193 | m_rc_tools(scrn.resourceManager(), "prevworkspace, workspacename, nextworkspace, iconbar, systemtray, clock", | 186 | m_rc_tools(scrn.resourceManager(), "prevworkspace, workspacename, nextworkspace, iconbar, systemtray, clock", |
194 | scrn.name() + ".toolbar.tools", scrn.altName() + ".Toolbar.Tools"), | 187 | scrn.name() + ".toolbar.tools"), |
195 | m_shape(new FbTk::Shape(frame.window, 0)), | 188 | m_shape(new FbTk::Shape(frame.window, 0)), |
196 | m_resize_lock(false) { | 189 | m_resize_lock(false) { |
197 | _FB_USES_NLS; | 190 | _FB_USES_NLS; |
@@ -239,7 +232,6 @@ Toolbar::Toolbar(BScreen &scrn, FbTk::Layer &layer, size_t width): | |||
239 | frame.window.showSubwindows(); | 232 | frame.window.showSubwindows(); |
240 | // frame.window.show(); | 233 | // frame.window.show(); |
241 | 234 | ||
242 | scrn.resourceManager().unlock(); | ||
243 | // setup to listen to child events | 235 | // setup to listen to child events |
244 | FbTk::EventManager::instance()->addParent(*this, window()); | 236 | FbTk::EventManager::instance()->addParent(*this, window()); |
245 | Fluxbox::instance()->keys()->registerWindow(window().window(), *this, | 237 | Fluxbox::instance()->keys()->registerWindow(window().window(), *this, |