forked from openlp/openlp
yet another go at minimizing ppt 2013
This commit is contained in:
parent
b0081a68b0
commit
f74413ebe0
@ -135,16 +135,10 @@ class PowerpointDocument(PresentationDocument):
|
||||
self.create_thumbnails()
|
||||
# Powerpoint 2013 pops up when loading a file, so we minimize it again
|
||||
if self.presentation.Application.Version == u'15.0':
|
||||
try:
|
||||
self.presentation.Application.ActiveWindow.WindowState = 2
|
||||
except:
|
||||
log.error(u'this failed: "self.presentation.Application.ActiveWindow.WindowState = 2", trying option 2...')
|
||||
log.error(sys.exc_info())
|
||||
try:
|
||||
self.presentation.Application.WindowState = 2
|
||||
except:
|
||||
log.error(u'option 2 failed as well')
|
||||
log.error(sys.exc_info())
|
||||
log.error(u'Failed to minimize main powerpoint window')
|
||||
|
||||
return True
|
||||
except pywintypes.com_error as e:
|
||||
@ -307,16 +301,10 @@ class PowerpointDocument(PresentationDocument):
|
||||
log.error(e)
|
||||
# Powerpoint 2013 pops up when starting a file, so we minimize it again
|
||||
if self.presentation.Application.Version == u'15.0':
|
||||
try:
|
||||
self.presentation.Application.ActiveWindow.WindowState = 2
|
||||
except:
|
||||
log.error(u'this failed: "self.presentation.Application.ActiveWindow.WindowState = 2", trying option 2...')
|
||||
log.error(sys.exc_info())
|
||||
try:
|
||||
self.presentation.Application.WindowState = 2
|
||||
except:
|
||||
log.error(u'option 2 failed as well')
|
||||
log.error(sys.exc_info())
|
||||
log.error(u'Failed to minimize main powerpoint window')
|
||||
|
||||
def get_slide_number(self):
|
||||
"""
|
||||
|
Loading…
Reference in New Issue
Block a user