diff options
| -rw-r--r-- | plugins/unityshell/src/unityshell.cpp | 34 | ||||
| -rw-r--r-- | plugins/unityshell/unityshell.xml.in | 6 | ||||
| -rw-r--r-- | unity-shared/UnitySettings.h | 1 |
3 files changed, 11 insertions, 30 deletions
diff --git a/plugins/unityshell/src/unityshell.cpp b/plugins/unityshell/src/unityshell.cpp index beda277ca..91ef4fc7e 100644 --- a/plugins/unityshell/src/unityshell.cpp +++ b/plugins/unityshell/src/unityshell.cpp @@ -292,25 +292,22 @@ UnityScreen::UnityScreen(CompScreen* screen) } //In case of software rendering then enable lowgfx mode. - std::string renderer = ANSI_TO_TCHAR(NUX_REINTERPRET_CAST(const char *, glGetString(GL_RENDERER))); g_autoptr(GSettings) gs = g_settings_new("com.canonical.Unity"); - if (g_settings_get_boolean(gs, "lowgfx")) - unity_settings_.low_gfx = true; - else - unity_settings_.low_gfx = false; + bool enable_lowgfx = g_settings_get_boolean(gs, "lowgfx"); + std::string renderer = ANSI_TO_TCHAR(NUX_REINTERPRET_CAST(const char *, glGetString(GL_RENDERER))); if (renderer.find("Software Rasterizer") != std::string::npos || - renderer.find("Mesa X11") != std::string::npos || - renderer.find("llvmpipe") != std::string::npos || - renderer.find("softpipe") != std::string::npos || - (getenv("UNITY_LOW_GFX_MODE") != NULL && atoi(getenv("UNITY_LOW_GFX_MODE")) == 1) || - optionGetLowGraphicsMode() - ) - { + renderer.find("Mesa X11") != std::string::npos || + renderer.find("llvmpipe") != std::string::npos || + renderer.find("softpipe") != std::string::npos || + (getenv("UNITY_LOW_GFX_MODE") != NULL && atoi(getenv("UNITY_LOW_GFX_MODE")) == 1) || + enable_lowgfx + ) + { unity_settings_.low_gfx = true; - } + } - if (getenv("UNITY_LOW_GFX_MODE") != NULL && atoi(getenv("UNITY_LOW_GFX_MODE")) == 0) + if (getenv("UNITY_LOW_GFX_MODE") != NULL && atoi(getenv("UNITY_LOW_GFX_MODE")) == 0 && (enable_lowgfx == false)) { unity_settings_.low_gfx = false; } @@ -389,7 +386,6 @@ UnityScreen::UnityScreen(CompScreen* screen) optionSetAutohideAnimationNotify(boost::bind(&UnityScreen::optionChanged, this, _1, _2)); optionSetDashBlurExperimentalNotify(boost::bind(&UnityScreen::optionChanged, this, _1, _2)); optionSetShortcutOverlayNotify(boost::bind(&UnityScreen::optionChanged, this, _1, _2)); - optionSetLowGraphicsModeNotify(boost::bind(&UnityScreen::optionChanged, this, _1, _2)); optionSetShowLauncherInitiate(boost::bind(&UnityScreen::showLauncherKeyInitiate, this, _1, _2, _3)); optionSetShowLauncherTerminate(boost::bind(&UnityScreen::showLauncherKeyTerminate, this, _1, _2, _3)); optionSetKeyboardFocusInitiate(boost::bind(&UnityScreen::setKeyboardFocusKeyInitiate, this, _1, _2, _3)); @@ -3742,14 +3738,6 @@ void UnityScreen::optionChanged(CompOption* opt, UnityshellOptions::Options num) case UnityshellOptions::ShortcutOverlay: shortcut_controller_->SetEnabled(optionGetShortcutOverlay()); break; - case UnityshellOptions::LowGraphicsMode: - if (optionGetLowGraphicsMode()) - BackgroundEffectHelper::blur_type = BLUR_NONE; - else - BackgroundEffectHelper::blur_type = (unity::BlurType)optionGetDashBlurExperimental(); - - unity::Settings::Instance().low_gfx = optionGetLowGraphicsMode(); - break; case UnityshellOptions::DecayRate: launcher_options->edge_decay_rate = optionGetDecayRate() * 100; break; diff --git a/plugins/unityshell/unityshell.xml.in b/plugins/unityshell/unityshell.xml.in index 1820f27d2..9294c5b26 100644 --- a/plugins/unityshell/unityshell.xml.in +++ b/plugins/unityshell/unityshell.xml.in @@ -160,12 +160,6 @@ <_long>Enables possibility to display an overlay showing available mouse and keyboard shortcuts.</_long> <default>true</default> </option> - - <option name="low_graphics_mode" type="bool"> - <_short>Enable Low Graphics Mode</_short> - <_long>Enables low graphics mode regardless of hardware in the system</_long> - <default>false</default> - </option> </group> <group> diff --git a/unity-shared/UnitySettings.h b/unity-shared/UnitySettings.h index 34009e794..b9d0358b4 100644 --- a/unity-shared/UnitySettings.h +++ b/unity-shared/UnitySettings.h @@ -76,7 +76,6 @@ public: nux::Property<bool> gestures_windows_drag_pinch; sigc::signal<void> dpi_changed; - sigc::signal<void> low_gfx_changed; sigc::signal<void> gestures_changed; private: |
