Use showMaximized #151

Merged
ghost merged 5 commits from master into master 2013-05-15 22:32:33 +02:00

View File

@ -465,13 +465,11 @@ class MyForm(QtGui.QMainWindow):
self.setWindowFlags(Qt.Window) self.setWindowFlags(Qt.Window)
self.show() self.show()
self.setWindowState(self.windowState() & ~QtCore.Qt.WindowMinimized | QtCore.Qt.WindowActive) self.setWindowState(self.windowState() & ~QtCore.Qt.WindowMinimized | QtCore.Qt.WindowActive)
self.activateWindow()
else: else:
self.show() self.showMaximized()
self.setWindowState(self.windowState() & QtCore.Qt.WindowMaximized)
#Here is what I believe might be required for darwin: #Here is what I believe might be required for darwin:
#self.setWindowState(self.windowState() & ~QtCore.Qt.WindowMinimized | QtCore.Qt.WindowActive) #self.setWindowState(self.windowState() & ~QtCore.Qt.WindowMinimized | QtCore.Qt.WindowActive)
#self.activateWindow() self.activateWindow()
# pointer to the application # pointer to the application
@ -626,6 +624,11 @@ class MyForm(QtGui.QMainWindow):
if not withMessagingMenu: if not withMessagingMenu:
return return
# if there are no items on the messaging menu then
# the subsequent query can be avoided
if not (self.mmapp.has_source("Subscriptions") or self.mmapp.has_source("Messages")):
return
shared.sqlLock.acquire() shared.sqlLock.acquire()
shared.sqlSubmitQueue.put('''SELECT toaddress, read FROM inbox WHERE msgid=?''') shared.sqlSubmitQueue.put('''SELECT toaddress, read FROM inbox WHERE msgid=?''')
shared.sqlSubmitQueue.put(inventoryHash) shared.sqlSubmitQueue.put(inventoryHash)