Remove deprecated stuff

This commit is contained in:
Fierelier 2022-06-08 21:12:02 +02:00
parent 85eb247823
commit 14eb91f84c
1 changed files with 1 additions and 3 deletions

View File

@ -37,7 +37,6 @@ sp = pUp(s)
# Comment the following line for hardware acceleration
os.environ["LIBGL_ALWAYS_SOFTWARE"] = "1"
#os.environ["WEBKIT_USE_SINGLE_WEB_PROCESS"] = "1" # Deprecated, not required with this code
import gi
gi.require_version("Gtk","3.0")
gi.require_version("WebKit2","4.0")
@ -66,7 +65,6 @@ def parseUrl(url):
birdyWebContext = WebKit2.WebContext()
birdyWebContext.set_cache_model(WebKit2.CacheModel.DOCUMENT_VIEWER) # Does this even do anything at all?
#birdyWebContext.set_process_model(WebKit2.ProcessModel.SHARED_SECONDARY_PROCESS) # Deprecated, not required with this code
birdyWebContext.set_spell_checking_enabled(False)
birdyWebContext.set_use_system_appearance_for_scrollbars(True)
@ -75,7 +73,7 @@ birdyWebSettings = WebKit2.Settings.new()
birdyWebSettings.set_enable_developer_extras(False)
birdyWebSettings.set_enable_page_cache(False)
birdyWebSettings.set_hardware_acceleration_policy(WebKit2.HardwareAccelerationPolicy.ALWAYS) # WebKit's software acceleration is broken, use LIBGL_ALWAYS_SOFTWARE=1 instead.
#birdyWebSettings.set_enable_plugins(False) # Probably best to not uncomment this, I think it causes a memory leak
birdyWebSettings.set_hardware_acceleration_policy(WebKit2.HardwareAccelerationPolicy.NEVER)
defaultUserAgent = birdyWebSettings.get_user_agent()
def birdyWebViewConstructor(webView):