Hello community, here is the log from the commit of package gnome-documents for openSUSE:Factory checked in at 2017-08-10 13:44:14 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/gnome-documents (Old) and /work/SRC/openSUSE:Factory/.gnome-documents.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "gnome-documents" Thu Aug 10 13:44:14 2017 rev:50 rq:511905 version:3.24.3 Changes: -------- --- /work/SRC/openSUSE:Factory/gnome-documents/gnome-documents.changes 2017-05-31 12:13:29.213380596 +0200 +++ /work/SRC/openSUSE:Factory/.gnome-documents.new/gnome-documents.changes 2017-08-10 13:44:14.675774281 +0200 @@ -1,0 +2,7 @@ +Fri Jul 21 13:20:36 UTC 2017 - zai...@opensuse.org + +- Update to version 3.24.3: + + Enable printing only for documents that support it. + + Avoid CRITICALs if a primary instance is already present. + +------------------------------------------------------------------- Old: ---- gnome-documents-3.24.2.tar.xz New: ---- gnome-documents-3.24.3.tar.xz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ gnome-documents.spec ++++++ --- /var/tmp/diff_new_pack.fCQdfV/_old 2017-08-10 13:44:16.075577227 +0200 +++ /var/tmp/diff_new_pack.fCQdfV/_new 2017-08-10 13:44:16.107572723 +0200 @@ -17,7 +17,7 @@ Name: gnome-documents -Version: 3.24.2 +Version: 3.24.3 Release: 0 Summary: Document Manager for GNOME License: GPL-2.0+ ++++++ gnome-documents-3.24.2.tar.xz -> gnome-documents-3.24.3.tar.xz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/gnome-documents-3.24.2/NEWS new/gnome-documents-3.24.3/NEWS --- old/gnome-documents-3.24.2/NEWS 2017-05-11 14:35:56.000000000 +0200 +++ new/gnome-documents-3.24.3/NEWS 2017-07-21 14:00:50.000000000 +0200 @@ -1,8 +1,14 @@ +3.24.3 - "Kern House" +===================== + +- Enable printing only for documents that support it +- Avoid CRITICALs if a primary instance is already present + 3.24.2 - "Sterling Cooper" ========================== - Unbreak previews of LOKDocView-supported documents from OneDrive -- Unreak caching of LOKDocView-supported documents from ownCloud +- Unbreak caching of LOKDocView-supported documents from ownCloud - Support previews of encrypted PDFs from Google - Pass the right number of arguments to LOKDocView.View.new - Translation updates diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/gnome-documents-3.24.2/configure new/gnome-documents-3.24.3/configure --- old/gnome-documents-3.24.2/configure 2017-05-11 14:39:45.000000000 +0200 +++ new/gnome-documents-3.24.3/configure 2017-07-21 14:04:27.000000000 +0200 @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.69 for gnome-documents 3.24.2. +# Generated by GNU Autoconf 2.69 for gnome-documents 3.24.3. # # # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. @@ -587,8 +587,8 @@ # Identity of this package. PACKAGE_NAME='gnome-documents' PACKAGE_TARNAME='gnome-documents' -PACKAGE_VERSION='3.24.2' -PACKAGE_STRING='gnome-documents 3.24.2' +PACKAGE_VERSION='3.24.3' +PACKAGE_STRING='gnome-documents 3.24.3' PACKAGE_BUGREPORT='' PACKAGE_URL='' @@ -1452,7 +1452,7 @@ # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures gnome-documents 3.24.2 to adapt to many kinds of systems. +\`configure' configures gnome-documents 3.24.3 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1523,7 +1523,7 @@ if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of gnome-documents 3.24.2:";; + short | recursive ) echo "Configuration of gnome-documents 3.24.3:";; esac cat <<\_ACEOF @@ -1661,7 +1661,7 @@ test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -gnome-documents configure 3.24.2 +gnome-documents configure 3.24.3 generated by GNU Autoconf 2.69 Copyright (C) 2012 Free Software Foundation, Inc. @@ -2060,7 +2060,7 @@ This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by gnome-documents $as_me 3.24.2, which was +It was created by gnome-documents $as_me 3.24.3, which was generated by GNU Autoconf 2.69. Invocation command line was $ $0 $@ @@ -3042,7 +3042,7 @@ # Define the identity of the package. PACKAGE='gnome-documents' - VERSION='3.24.2' + VERSION='3.24.3' cat >>confdefs.h <<_ACEOF @@ -19989,7 +19989,7 @@ # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by gnome-documents $as_me 3.24.2, which was +This file was extended by gnome-documents $as_me 3.24.3, which was generated by GNU Autoconf 2.69. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -20055,7 +20055,7 @@ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ -gnome-documents config.status 3.24.2 +gnome-documents config.status 3.24.3 configured by $0, generated by GNU Autoconf 2.69, with options \\"\$ac_cs_config\\" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/gnome-documents-3.24.2/configure.ac new/gnome-documents-3.24.3/configure.ac --- old/gnome-documents-3.24.2/configure.ac 2017-05-11 14:31:01.000000000 +0200 +++ new/gnome-documents-3.24.3/configure.ac 2017-07-21 13:59:17.000000000 +0200 @@ -1,6 +1,6 @@ dnl -*- mode: m4 -*- AC_PREREQ(2.63) -AC_INIT([gnome-documents],[3.24.2],[],[gnome-documents]) +AC_INIT([gnome-documents],[3.24.3],[],[gnome-documents]) AC_CONFIG_HEADERS([config/config.h]) AC_CONFIG_SRCDIR([src/main.js]) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/gnome-documents-3.24.2/src/application.js new/gnome-documents-3.24.3/src/application.js --- old/gnome-documents-3.24.2/src/application.js 2017-05-11 14:20:06.000000000 +0200 +++ new/gnome-documents-3.24.3/src/application.js 2017-07-21 13:56:32.000000000 +0200 @@ -103,6 +103,7 @@ this.minersRunning = []; this._activationTimestamp = Gdk.CURRENT_TIME; this._extractPriority = null; + this._searchProvider = null; this.isBooks = isBooks; @@ -123,10 +124,6 @@ this.add_main_option('version', 'v'.charCodeAt(0), GLib.OptionFlags.NONE, GLib.OptionArg.NONE, _("Show the version of the program"), null); - - this._searchProvider = new ShellSearchProvider.ShellSearchProvider(); - this._searchProvider.connect('activate-result', Lang.bind(this, this._onActivateResult)); - this._searchProvider.connect('launch-search', Lang.bind(this, this._onLaunchSearch)); }, _initGettingStarted: function() { @@ -444,12 +441,28 @@ vfunc_dbus_register: function(connection, path) { this.parent(connection, path); - this._searchProvider.export(connection); + if (this._searchProvider != null) + throw(new Error('ShellSearchProvider already instantiated - dbus_register called twice?')); + + this._searchProvider = new ShellSearchProvider.ShellSearchProvider(); + this._searchProvider.connect('activate-result', Lang.bind(this, this._onActivateResult)); + this._searchProvider.connect('launch-search', Lang.bind(this, this._onLaunchSearch)); + + try { + this._searchProvider.export(connection); + } catch(e) { + this._searchProvider = null; + throw(e); + } + return true; }, vfunc_dbus_unregister: function(connection, path) { - this._searchProvider.unexport(connection); + if (this._searchProvider != null) { + this._searchProvider.unexport(connection); + this._searchProvider = null; + } this.parent(connection, path); }, diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/gnome-documents-3.24.2/src/documents.js new/gnome-documents-3.24.3/src/documents.js --- old/gnome-documents-3.24.2/src/documents.js 2017-05-11 14:20:12.000000000 +0200 +++ new/gnome-documents-3.24.3/src/documents.js 2017-07-21 13:56:32.000000000 +0200 @@ -36,6 +36,7 @@ const _ = imports.gettext.gettext; const Lang = imports.lang; +const Mainloop = imports.mainloop; const Signals = imports.signals; const Application = imports.application; @@ -413,6 +414,20 @@ load: function(passwd, cancellable, callback) { Utils.debug('Loading ' + this.__name__ + ' ' + this.id); + + if (this.collection) { + Mainloop.idle_add(Lang.bind(this, + function() { + let error = new GLib.Error(Gio.IOErrorEnum, + Gio.IOErrorEnum.NOT_SUPPORTED, + "Collections can't be loaded"); + callback(this, null, error); + return GLib.SOURCE_REMOVE; + })); + + return; + } + this.download(true, cancellable, Lang.bind(this, function(fromCache, error) { if (error) { @@ -459,6 +474,9 @@ }, canPrint: function(docModel) { + if (this.collection) + return false; + if (!docModel) return false; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/gnome-documents-3.24.2/src/selections.js new/gnome-documents-3.24.3/src/selections.js --- old/gnome-documents-3.24.2/src/selections.js 2017-05-11 14:20:06.000000000 +0200 +++ new/gnome-documents-3.24.3/src/selections.js 2017-07-21 13:56:32.000000000 +0200 @@ -922,7 +922,7 @@ let hasSelection = (selection.length > 0); let showTrash = hasSelection; - let showPrint = hasSelection; + let showPrint = false; let showProperties = hasSelection; let showOpen = hasSelection; let showShare = hasSelection; @@ -943,16 +943,22 @@ showShare = false; showTrash &= doc.canTrash(); - showPrint &= !doc.collection; })); showOpen = (apps.length > 0); - if (selection.length > 1) { - showPrint = false; - showProperties = false; + if (selection.length == 1) { + let doc = Application.documentManager.getItemById(selection[0]); + doc.load(null, null, Lang.bind(this, + function(doc, docModel, error) { + showPrint = doc.canPrint(docModel); + this._toolbarPrint.set_sensitive(showPrint); + })); } + if (selection.length > 1) + showProperties = false; + let openLabel = null; if (apps.length == 1) { // Translators: this is the Open action in a context menu