diff options
Diffstat (limited to 'examples/update-file-info-async.py')
-rw-r--r-- | examples/update-file-info-async.py | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/examples/update-file-info-async.py b/examples/update-file-info-async.py index 349b169..e4f90c7 100644 --- a/examples/update-file-info-async.py +++ b/examples/update-file-info-async.py @@ -1,15 +1,14 @@ -import caja -import gobject +from gi.repository import Caja, GObject -class UpdateFileInfoAsync(caja.InfoProvider): +class UpdateFileInfoAsync(GObject.GObject, Caja.InfoProvider): def __init__(self): pass def update_file_info_full(self, provider, handle, closure, file): print "update_file_info_full" gobject.timeout_add_seconds(3, self.update_cb, provider, handle, closure) - return caja.OPERATION_IN_PROGRESS + return Caja.OperationResult.IN_PROGRESS def update_cb(self, provider, handle, closure): print "update_cb" - self.update_complete_invoke(provider, handle, closure, result=caja.OPERATION_FAILED) + Caja.info_provider_update_complete_invoke(closure, provider, handle, Caja.OperationResult.FAILED) |