pyloid 0.23.13__tar.gz → 0.23.15__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: pyloid
3
- Version: 0.23.13
3
+ Version: 0.23.15
4
4
  Summary:
5
5
  Author: aesthetics-of-record
6
6
  Author-email: 111675679+aesthetics-of-record@users.noreply.github.com
@@ -1,6 +1,6 @@
1
1
  [tool.poetry]
2
2
  name = "pyloid"
3
- version = "0.23.13"
3
+ version = "0.23.15"
4
4
  description = ""
5
5
  authors = ["aesthetics-of-record <111675679+aesthetics-of-record@users.noreply.github.com>"]
6
6
  readme = "README.md"
@@ -928,6 +928,9 @@ class _BrowserWindow:
928
928
  >>> window = app.create_window("pyloid-window")
929
929
  >>> window.show()
930
930
  """
931
+ # 최소화 상태라면 먼저 복원
932
+ if self._window.isMinimized():
933
+ self._window.showNormal()
931
934
  self._window.show()
932
935
 
933
936
  def focus(self):
@@ -940,14 +943,8 @@ class _BrowserWindow:
940
943
  >>> window = app.create_window("pyloid-window")
941
944
  >>> window.focus()
942
945
  """
943
- was_on_top = bool(self._window.windowFlags() & Qt.WindowStaysOnTopHint)
944
- if not was_on_top:
945
- self._window.setWindowFlag(Qt.WindowStaysOnTopHint, True)
946
- self._window.show()
946
+ self._window.raise_()
947
947
  self._window.activateWindow()
948
- if not was_on_top:
949
- self._window.setWindowFlag(Qt.WindowStaysOnTopHint, False)
950
- self._window.show()
951
948
 
952
949
  def show_and_focus(self):
953
950
  """
@@ -959,14 +956,23 @@ class _BrowserWindow:
959
956
  >>> window = app.create_window("pyloid-window")
960
957
  >>> window.show_and_focus()
961
958
  """
962
- was_on_top = bool(self._window.windowFlags() & Qt.WindowStaysOnTopHint)
963
- if not was_on_top:
964
- self._window.setWindowFlag(Qt.WindowStaysOnTopHint, True)
965
- self._window.show()
959
+ # 최소화 상태라면 먼저 복원
960
+ if self._window.isMinimized():
961
+ self._window.showNormal()
962
+ self._window.show()
963
+ self._window.raise_()
966
964
  self._window.activateWindow()
967
- if not was_on_top:
968
- self._window.setWindowFlag(Qt.WindowStaysOnTopHint, False)
969
- self._window.show()
965
+
966
+ # was_on_top = bool(self._window.windowFlags() & Qt.WindowStaysOnTopHint)
967
+ # if not was_on_top:
968
+ # self._window.setWindowFlag(Qt.WindowStaysOnTopHint, True)
969
+ # self._window.show()
970
+
971
+ # self._window.activateWindow()
972
+
973
+ # if not was_on_top:
974
+ # self._window.setWindowFlag(Qt.WindowStaysOnTopHint, False)
975
+ # self._window.show()
970
976
 
971
977
  def close(self):
972
978
  """
@@ -419,20 +419,8 @@ class _Pyloid(QApplication):
419
419
  ```
420
420
  """
421
421
  if self.windows_dict:
422
- # 첫 번째 윈도우 가져오기
423
422
  main_window = next(iter(self.windows_dict.values()))
424
- was_on_top = bool(
425
- main_window._window._window.windowFlags() & Qt.WindowStaysOnTopHint
426
- )
427
- if not was_on_top:
428
- main_window._window._window.setWindowFlag(Qt.WindowStaysOnTopHint, True)
429
- main_window._window._window.show()
430
- main_window._window.activateWindow()
431
- if not was_on_top:
432
- main_window._window._window.setWindowFlag(
433
- Qt.WindowStaysOnTopHint, False
434
- )
435
- main_window._window._window.show()
423
+ main_window.focus()
436
424
 
437
425
  def show_and_focus_main_window(self):
438
426
  """
@@ -446,21 +434,8 @@ class _Pyloid(QApplication):
446
434
  ```
447
435
  """
448
436
  if self.windows_dict:
449
- main_window = next(iter(self.windows_dict.values()))
450
- main_window._window.show()
451
-
452
- was_on_top = bool(
453
- main_window._window._window.windowFlags() & Qt.WindowStaysOnTopHint
454
- )
455
- if not was_on_top:
456
- main_window._window._window.setWindowFlag(Qt.WindowStaysOnTopHint, True)
457
- main_window._window._window.show()
458
- main_window._window._window.activateWindow()
459
- if not was_on_top:
460
- main_window._window._window.setWindowFlag(
461
- Qt.WindowStaysOnTopHint, False
462
- )
463
- main_window._window._window.show()
437
+ main_window = next(iter(self.windows_dict.values()))
438
+ main_window.show_and_focus()
464
439
 
465
440
  def close_all_windows(self):
466
441
  """
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes