forked from cromer/pamac-classic
small fixes
This commit is contained in:
parent
3aa7b124a0
commit
76714eedb8
@ -11,6 +11,7 @@
|
||||
<property name="skip_taskbar_hint">True</property>
|
||||
<property name="urgency_hint">True</property>
|
||||
<property name="deletable">False</property>
|
||||
<property name="transient_for">ManagerWindow</property>
|
||||
<child internal-child="vbox">
|
||||
<object class="GtkBox" id="dialog-vbox1">
|
||||
<property name="can_focus">False</property>
|
||||
@ -122,6 +123,7 @@
|
||||
<property name="skip_taskbar_hint">True</property>
|
||||
<property name="urgency_hint">True</property>
|
||||
<property name="deletable">False</property>
|
||||
<property name="transient_for">ManagerWindow</property>
|
||||
<child>
|
||||
<object class="GtkBox" id="box7">
|
||||
<property name="visible">True</property>
|
||||
@ -214,6 +216,7 @@
|
||||
<property name="can_focus">False</property>
|
||||
<property name="margin_left">7</property>
|
||||
<property name="margin_right">7</property>
|
||||
<property name="margin_bottom">9</property>
|
||||
<property name="spacing">7</property>
|
||||
<property name="homogeneous">True</property>
|
||||
<property name="layout_style">end</property>
|
||||
|
@ -7,7 +7,8 @@ from dbus.mainloop.glib import DBusGMainLoop
|
||||
from gi.repository import GObject
|
||||
|
||||
import pyalpm
|
||||
import traceback
|
||||
#import traceback
|
||||
#import threading
|
||||
from pamac import config, common
|
||||
|
||||
class PamacDBusService(dbus.service.Object):
|
||||
@ -295,7 +296,7 @@ class PamacDBusService(dbus.service.Object):
|
||||
except pyalpm.error as e:
|
||||
#error = traceback.format_exc()
|
||||
self.error += ' --> '+str(e)+'\n'
|
||||
#nosuccess(error)
|
||||
#nosuccess(self.error)
|
||||
#except dbus.exceptions.DBusException:
|
||||
#pass
|
||||
finally:
|
||||
@ -303,6 +304,7 @@ class PamacDBusService(dbus.service.Object):
|
||||
return self.error
|
||||
else :
|
||||
return 'You are not authorized'
|
||||
#nosuccess('You are not authorized')
|
||||
|
||||
@dbus.service.method('org.manjaro.pamac', '', 's', sender_keyword='sender', connection_keyword='connexion')
|
||||
def Release(self, sender=None, connexion=None):
|
||||
|
@ -54,7 +54,7 @@ def action_signal_handler(action):
|
||||
# ProgressCancelButton.set_visible(True)
|
||||
#else:
|
||||
ProgressCancelButton.set_visible(False)
|
||||
#print('cancel disabled')
|
||||
#print('cancel disabled')
|
||||
|
||||
def icon_signal_handler(icon):
|
||||
action_icon.set_from_file(icon)
|
||||
@ -276,14 +276,17 @@ def handle_error(error):
|
||||
global transaction_type
|
||||
global transaction_dict
|
||||
if error:
|
||||
if not 'DBus.Error.NoReply' in error:
|
||||
print('error',error)
|
||||
if not 'DBus.Error.NoReply' in str(error):
|
||||
print('error:', error)
|
||||
transaction.ErrorDialog.format_secondary_text(error)
|
||||
response = transaction.ErrorDialog.run()
|
||||
if response:
|
||||
transaction.ErrorDialog.hide()
|
||||
transaction.t_lock = False
|
||||
transaction.Release()
|
||||
try:
|
||||
transaction.Release()
|
||||
except:
|
||||
pass
|
||||
ProgressWindow.hide()
|
||||
if mode == 'manager':
|
||||
transaction.to_add = []
|
||||
@ -295,7 +298,6 @@ def handle_error(error):
|
||||
set_packages_list()
|
||||
if mode == 'updater':
|
||||
have_updates()
|
||||
print('error',error)
|
||||
|
||||
def handle_reply(reply):
|
||||
global transaction_type
|
||||
@ -306,7 +308,10 @@ def handle_reply(reply):
|
||||
if response:
|
||||
transaction.ErrorDialog.hide()
|
||||
transaction.t_lock = False
|
||||
transaction.Release()
|
||||
try:
|
||||
transaction.Release()
|
||||
except:
|
||||
pass
|
||||
ProgressWindow.hide()
|
||||
transaction.to_add = []
|
||||
transaction.to_remove = []
|
||||
@ -796,7 +801,7 @@ class Handler:
|
||||
|
||||
def on_ProgressCancelButton_clicked(self, *arg):
|
||||
print('cancelled')
|
||||
#handle_reply('')
|
||||
handle_reply('')
|
||||
|
||||
def main(_mode):
|
||||
if common.pid_file_exists():
|
||||
|
Loading…
Reference in New Issue
Block a user