diff options
| author | Tim Penhey <tim.penhey@canonical.com> | 2012-02-09 08:54:15 +1300 |
|---|---|---|
| committer | Tim Penhey <tim.penhey@canonical.com> | 2012-02-09 08:54:15 +1300 |
| commit | 0b11eb7ca21c32003ba6795bcbc5e615955c8329 (patch) | |
| tree | bcdb08f09ebea049519b6304cfac08ecae014b2b | |
| parent | 4e7bb655d6b11d9d3994a8a2615b6a11bae0eed7 (diff) | |
Use Adopt not assignment for taking textures as they are initially owned.
(bzr r1926.1.1)
| -rw-r--r-- | plugins/unityshell/src/UnityWindowStyle.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/plugins/unityshell/src/UnityWindowStyle.cpp b/plugins/unityshell/src/UnityWindowStyle.cpp index 826f7669d..348688ff8 100644 --- a/plugins/unityshell/src/UnityWindowStyle.cpp +++ b/plugins/unityshell/src/UnityWindowStyle.cpp @@ -24,9 +24,9 @@ namespace ui { UnityWindowStyle::UnityWindowStyle() { - background_top_ = BaseTexturePtr(nux::CreateTexture2DFromFile(PKGDATADIR"/switcher_top.png", -1, true)); - background_left_ = BaseTexturePtr(nux::CreateTexture2DFromFile(PKGDATADIR"/switcher_left.png", -1, true)); - background_corner_ = BaseTexturePtr(nux::CreateTexture2DFromFile(PKGDATADIR"/switcher_corner.png", -1, true)); + background_top_.Adopt(nux::CreateTexture2DFromFile(PKGDATADIR"/switcher_top.png", -1, true)); + background_left_.Adopt(nux::CreateTexture2DFromFile(PKGDATADIR"/switcher_left.png", -1, true)); + background_corner_.Adopt(nux::CreateTexture2DFromFile(PKGDATADIR"/switcher_corner.png", -1, true)); } UnityWindowStyle::~UnityWindowStyle() @@ -61,4 +61,4 @@ nux::BaseTexture* UnityWindowStyle::GetBackgroundCorner() const } -} \ No newline at end of file +} |
