Changeset 44:e087b878bc49 in SMSSender for src/ui/models/accountmodel.cpp


Ignore:
Timestamp:
Jan 28, 2010 3:54:36 PM (12 years ago)
Author:
Sämy Zehnder <saemy.zehnder@…>
Branch:
3.0
Convert:
svn:3639001d-8e34-449c-bb86-3782b86c4877/branches/3.0@43
Message:
  • Removed unused libraries from project-files.
  • Fixed segfault on account creation (the default storage for a gateway is assigned at startup now; not in account loading, which was erroneous)
  • Removed versioning from Makefiles
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/ui/models/accountmodel.cpp

    r43 r44  
    77{
    88    connect(BCAccountManager::instance(), SIGNAL(accountAdded(IAccount*)),
    9             this, SLOT(accountDataChanged(IAccount*)));
     9            this, SLOT(accountUpdated(IAccount*)));
    1010    connect(BCAccountManager::instance(), SIGNAL(accountDataChanged(IAccount*)),
    11             this, SLOT(accountDataChanged(IAccount*)));
     11            this, SLOT(accountUpdated(IAccount*)));
    1212    connect(BCAccountManager::instance(), SIGNAL(accountRemoved(IAccount*)),
    13             this, SLOT(accountDataChanged(IAccount*)));
     13            this, SLOT(accountUpdated(IAccount*)));
    1414}
    1515AccountModel::~AccountModel() {
    1616    disconnect(BCAccountManager::instance(), SIGNAL(accountAdded(IAccount*)),
    17                this, SLOT(accountDataChanged(IAccount*)));
     17               this, SLOT(accountUpdated(IAccount*)));
    1818    disconnect(BCAccountManager::instance(), SIGNAL(accountDataChanged(IAccount*)),
    19                this, SLOT(accountDataChanged(IAccount*)));
     19               this, SLOT(accountUpdated(IAccount*)));
    2020    disconnect(BCAccountManager::instance(), SIGNAL(accountRemoved(IAccount*)),
    21                this, SLOT(accountDataChanged(IAccount*)));
     21               this, SLOT(accountUpdated(IAccount*)));
    2222}
    2323
     
    2727    QModelIndex idx_start = index(row, 0);
    2828    QModelIndex idx_end   = index(row, COL_COUNT);
    29     emit dataChanged(idx_start, idx_end);
     29
     30    if (idx_start.isValid() && idx_end.isValid()) {
     31        emit dataChanged(idx_start, idx_end);
     32    } else {
     33        reset();
     34    }
    3035}
    3136
Note: See TracChangeset for help on using the changeset viewer.