URI: 
       tqt swap_dialog: clean-up imports - electrum - Electrum Bitcoin wallet
  HTML git clone https://git.parazyd.org/electrum
   DIR Log
   DIR Files
   DIR Refs
   DIR Submodules
       ---
   DIR commit a98fd14f8d9b9c1d17fd6c25d58cc4b72a6fd8b4
   DIR parent 2be2a510fff02ef30c74749d30f741a61834f186
  HTML Author: SomberNight <somber.night@protonmail.com>
       Date:   Thu, 18 Jun 2020 19:58:23 +0200
       
       qt swap_dialog: clean-up imports
       
       Diffstat:
         M electrum/gui/qt/swap_dialog.py      |      27 ++++++++++-----------------
       
       1 file changed, 10 insertions(+), 17 deletions(-)
       ---
   DIR diff --git a/electrum/gui/qt/swap_dialog.py b/electrum/gui/qt/swap_dialog.py
       t@@ -1,26 +1,18 @@
       -from PyQt5 import QtCore, QtGui
       -from PyQt5.QtCore import Qt
       -from PyQt5.QtWidgets import (QMenu, QHBoxLayout, QLabel, QVBoxLayout, QGridLayout, QLineEdit,
       -                             QPushButton, QAbstractItemView, QComboBox)
       -from PyQt5.QtGui import QFont, QStandardItem, QBrush
       +from typing import TYPE_CHECKING
       +
       +from PyQt5.QtWidgets import QLabel, QVBoxLayout, QGridLayout, QPushButton
        
       -from electrum.util import bh2u, NotEnoughFunds, NoDynamicFeeEstimates
        from electrum.i18n import _
       -from electrum.lnchannel import AbstractChannel, PeerState
       -from electrum.wallet import Abstract_Wallet
       -from electrum.lnutil import LOCAL, REMOTE, format_short_channel_id, LN_MAX_FUNDING_SAT
        from electrum.lnutil import ln_dummy_address
       -from electrum.lnworker import LNWallet
        from electrum.transaction import PartialTxOutput
        
       -from .util import (MyTreeView, WindowModalDialog, Buttons, OkButton, CancelButton,
       -                   EnterButton, WaitingDialog, MONOSPACE_FONT, ColorScheme)
       -from .amountedit import BTCAmountEdit, FreezableLineEdit
       -from .util import WWLabel
       +from .util import (WindowModalDialog, Buttons, OkButton, CancelButton,
       +                   EnterButton, ColorScheme, WWLabel, read_QIcon)
       +from .amountedit import BTCAmountEdit
        from .fee_slider import FeeSlider, FeeComboBox
        
       -import asyncio
       -from .util import read_QIcon
       +if TYPE_CHECKING:
       +    from .main_window import ElectrumWindow
        
        CANNOT_RECEIVE_WARNING = """
        The requested amount is higher than what you can receive in your currently open channels.
       t@@ -29,9 +21,10 @@ If the swap cannot be performed after 24h, you will be refunded.
        Do you want to continue?
        """
        
       +
        class SwapDialog(WindowModalDialog):
        
       -    def __init__(self, window):
       +    def __init__(self, window: 'ElectrumWindow'):
                WindowModalDialog.__init__(self, window, _('Submarine Swap'))
                self.window = window
                self.config = window.config