Skip to content

Commit

Permalink
Merge pull request Tribler#7463 from kozlovsky/fix/unminimizing_when_…
Browse files Browse the repository at this point in the history
…clicking_on_file

Fix/unminimizing when clicking on file
  • Loading branch information
kozlovsky authored Jun 7, 2023
2 parents 15de5c8 + afed37c commit 035b623
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
3 changes: 2 additions & 1 deletion src/tribler/gui/single_application.py
Original file line number Diff line number Diff line change
Expand Up @@ -89,11 +89,12 @@ def _on_new_connection(self):
self._incoming_stream.setCodec('UTF-8')
connect(self._incoming_connection.readyRead, self._on_ready_read)
if self.tribler_window:
self.tribler_window.restore_from_minimised()
self.tribler_window.raise_window()

def _on_ready_read(self):
while True:
msg = self._incoming_stream.readLine()
if not msg:
break
self.logger.info(f'A message received via the local socket: {msg}')
self.message_received.emit(msg)
4 changes: 0 additions & 4 deletions src/tribler/gui/tribler_window.py
Original file line number Diff line number Diff line change
Expand Up @@ -1250,10 +1250,6 @@ def keyPressEvent(self, event: QKeyEvent) -> None:
if event.key() == Qt.Key_Escape:
self.escape_pressed.emit()

def restore_from_minimised(self):
self.setWindowState(self.windowState() & ~Qt.WindowMinimized)
self.raise_()

def handle_uri(self, uri):
self.pending_uri_requests.append(uri)
if self.tribler_started and not self.start_download_dialog_active:
Expand Down

0 comments on commit 035b623

Please sign in to comment.