diff options
author | fluxgen <fluxgen> | 2006-03-18 21:59:44 (GMT) |
---|---|---|
committer | fluxgen <fluxgen> | 2006-03-18 21:59:44 (GMT) |
commit | 4b4c46559b52f94103be060b2e182b1d22d10989 (patch) | |
tree | f8b95c5c60e144492f733297eb3f34da98a0a654 /src | |
parent | bdc74e79958ee5af9f191edefbdc5652320d1ad7 (diff) | |
download | fluxbox_pavel-4b4c46559b52f94103be060b2e182b1d22d10989.zip fluxbox_pavel-4b4c46559b52f94103be060b2e182b1d22d10989.tar.bz2 |
added addManagedResource, which adds a resource to BScreen and will be destroy by BScreen
Diffstat (limited to 'src')
-rw-r--r-- | src/Screen.hh | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/Screen.hh b/src/Screen.hh index 7954456..1858829 100644 --- a/src/Screen.hh +++ b/src/Screen.hh | |||
@@ -352,6 +352,10 @@ public: | |||
352 | void removeConfigMenu(FbTk::Menu &menu); | 352 | void removeConfigMenu(FbTk::Menu &menu); |
353 | 353 | ||
354 | 354 | ||
355 | /// Adds a resource to managed resource list | ||
356 | /// This resource is now owned by Screen and will be destroyed | ||
357 | /// when screen dies | ||
358 | void addManagedResource(FbTk::Resource_base *resource); | ||
355 | 359 | ||
356 | class ScreenSubject:public FbTk::Subject { | 360 | class ScreenSubject:public FbTk::Subject { |
357 | public: | 361 | public: |
@@ -445,6 +449,9 @@ private: | |||
445 | 449 | ||
446 | } resource; | 450 | } resource; |
447 | 451 | ||
452 | /// Holds manage resources that screen destroys | ||
453 | FbTk::ResourceManager::ResourceList m_managed_resources; | ||
454 | |||
448 | FbTk::ResourceManager &m_resource_manager; | 455 | FbTk::ResourceManager &m_resource_manager; |
449 | const std::string m_name, m_altname; | 456 | const std::string m_name, m_altname; |
450 | 457 | ||