From c84af0839782820ff42a8cf08c3b76d830f77757 Mon Sep 17 00:00:00 2001 From: Tomeu Vizoso Date: Wed, 13 Jun 2007 12:16:03 +0000 Subject: Implement get_doc_shell in python. --- (limited to 'python') diff --git a/python/hulahop.defs b/python/hulahop.defs index 8fafc59..4f18c2d 100644 --- a/python/hulahop.defs +++ b/python/hulahop.defs @@ -29,12 +29,6 @@ (return-type "none") ) -(define-method get_doc_shell - (of-object "HulahopWebView") - (c-name "hulahop_web_view_get_doc_shell") - (return-type "none") -) - (define-function startup (c-name "hulahop_startup") (return-type "gboolean") diff --git a/python/hulahop.override b/python/hulahop.override index 4353268..d846c64 100644 --- a/python/hulahop.override +++ b/python/hulahop.override @@ -29,10 +29,3 @@ _wrap_hulahop_web_view_get_window_root(PyGObject *self) return hulahop_web_view_get_window_root(HULAHOP_WEB_VIEW(self->obj)); } %% -override hulahop_web_view_get_doc_shell noargs -static PyObject * -_wrap_hulahop_web_view_get_doc_shell(PyGObject *self) -{ - return hulahop_web_view_get_doc_shell(HULAHOP_WEB_VIEW(self->obj)); -} -%% diff --git a/python/webview.py b/python/webview.py index 7f2534e..1c2a80c 100644 --- a/python/webview.py +++ b/python/webview.py @@ -193,7 +193,8 @@ class WebView(_hulahop.WebView): return _hulahop.WebView.get_browser(self) def get_doc_shell(self): - return _hulahop.WebView.get_doc_shell(self) + requestor = self.browser.queryInterface(interfaces.nsIInterfaceRequestor) + return requestor.getInterface(interfaces.nsIDocShell) def get_web_progress(self): return self.doc_shell.queryInterface(interfaces.nsIWebProgress) -- cgit v0.9.1