URI: 
       tdefine method get_address_flags - electrum - Electrum Bitcoin wallet
  HTML git clone https://git.parazyd.org/electrum
   DIR Log
   DIR Files
   DIR Refs
   DIR Submodules
       ---
   DIR commit 9625ef1ea902b14d47f36d5d0416537a5aee9030
   DIR parent 7ba656a1bc68e66e231bb8294a3be6a3ac5c9993
  HTML Author: thomasv <thomasv@gitorious>
       Date:   Thu,  7 Jun 2012 16:14:08 +0200
       
       define method get_address_flags
       
       Diffstat:
         M electrum                            |       5 ++---
         M lib/gui_qt.py                       |       3 ++-
         M lib/wallet.py                       |       4 ++++
       
       3 files changed, 8 insertions(+), 4 deletions(-)
       ---
   DIR diff --git a/electrum b/electrum
       t@@ -380,10 +380,9 @@ if __name__ == '__main__':
                for addr in wallet.all_addresses():
                    if options.show_all or not wallet.is_change(addr):
        
       -                flags = "C" if wallet.is_change(addr) else "I" if addr in wallet.imported_keys.keys() else "-" 
       -                flags += "F" if addr in wallet.frozen_addresses else "P" if addr in wallet.prioritized_addresses else "-" 
       -
       +                flags = wallet.get_address_flags(addr)
                        label = wallet.labels.get(addr,'')
       +                
                        if label: label = "\"%s\""%label
        
                        if options.show_balance:
   DIR diff --git a/lib/gui_qt.py b/lib/gui_qt.py
       t@@ -693,9 +693,10 @@ class ElectrumWindow(QMainWindow):
        
                    c, u = self.wallet.get_addr_balance(address)
                    balance = format_satoshis( c + u, False, self.wallet.num_zeros )
       -            flags = '--'
       +            flags = self.wallet.get_address_flags(address)
                    item = QTreeWidgetItem( [ flags, address, label, balance, tx] )
        
       +            item.setFont(0, QFont(MONOSPACE_FONT))
                    item.setFont(1, QFont(MONOSPACE_FONT))
                    if address in self.wallet.frozen_addresses: 
                        item.setBackgroundColor(1, QColor('lightblue'))
   DIR diff --git a/lib/wallet.py b/lib/wallet.py
       t@@ -623,6 +623,10 @@ class Wallet:
                self.file_exists = True
        
        
       +    def get_address_flags(self, addr):
       +        flags = "C" if self.is_change(addr) else "I" if addr in self.imported_keys.keys() else "-" 
       +        flags += "F" if addr in self.frozen_addresses else "P" if addr in self.prioritized_addresses else "-"
       +        return flags
                
        
            def get_addr_balance(self, addr):