Short Description: AccountGfxItem: preparation for supporting multiple Accts Bug Number: n/a Release notes (y/n): no For Release Nums: 6.1 Modifed AccountGfxItem design from supporting a single Account to multiple Accounts, in preparation for Account Icon Aggregation (controlled by an Account Display Group property). ------------------ AccountGfxItem.hpp AccountGfxItem.cpp ------------------ AccountGfxItems now maintain a SET of referenced Accounts, and conditionally self-delete when the last remaining Account is removed. Multiple-Account drawing is not yet implemented. However, for now, if the Item represents several Accounts (which would be in a single Account Display Group), the Account Display Group name is shown instead of an Account Name. The ToolTip text now shows one line of text for each of the supported Accounts. Also, for Accounts on AggregateObj Elements, the Element name is shown in the ToolTip (before the Account Name, like this: element^account). ACCOUNT_DELETED callbacks now result in the Account being removed from the list of Accounts supported by this item. And if the Account count becomes zero, the AccountGfxItem self-deletes. Removed: Account* _account; SimObj* _simObj; Callback* _acctCallback; Added: QList _accountList; QMap _acctCallbackMap; QString _groupName; bool _isAggregation; // does this item represent an Account Aggregation? Added 'doSelfDelete' parameter to these methods: void prepareForDeletion (bool doSelfDelete); bool removeAccount (Account*, bool doSelfDelete); void removeAccounts (bool doSelfDelete); Additional other methods to support multiple Accounts: Account* firstAccount() const; const QList& accountListRef() const { return _accountList; } bool containsAccount (Account*) const; void addAccount (Account*); ------------------ AcctRowGfxItem.hpp AcctRowGfxItem.cpp ------------------ This class now keeps track of AccountGfxItem children directly, rather than maintaining a list of Accounts, and relating those Accounts individually with an AccountGfxItem. For now, only single-Account AccountGfxItems are ever created. The next develoment task is to create multiple-Account Items based on Account Display Group settings. OLD: QList _accountList; NEW: QList _accountItemList; See especially changes in methods: void AcctRowGfxItem::removeAccount (Account* acct) void AcctRowGfxItem::removeAccountItem (const AccountGfxItem* deadItem) void AcctRowGfxItem::clearAccountItems() void AcctRowGfxItem::accountGfxItemDeleted (const AccountGfxItem*) // slot ---------------------- SimObjGfxItem.hpp SimObjGfxItem.cpp SimulationGfxScene.cpp WorkspaceGfxScene.cpp WorkspaceGfxScene.hpp WorkspaceGfxView.cpp ---------------------- Client changes for change in AcctRowGfxItem and AccountGfxItem architecural change (vis-a-vis Account Items potentially supporting multiple Accounts based on Account Group names). ------------------- RwGraphicsScene.hpp RwGraphicsScene.cpp ------------------- Added utilities: // Enable/Disable Qt Updates in All RwGrahicsViews void setUpdatesEnabledInViews (bool ena); bool updatesEnabledInMainView() const; ---