| 1 | /*************************************************************************** |
| 2 | * Copyright (C) 2009 by The qGo Project * |
| 3 | * * |
| 4 | * This file is part of qGo. * |
| 5 | * * |
| 6 | * qGo is free software: you can redistribute it and/or modify * |
| 7 | * it under the terms of the GNU General Public License as published by * |
| 8 | * the Free Software Foundation; either version 2 of the License, or * |
| 9 | * (at your option) any later version. * |
| 10 | * * |
| 11 | * This program is distributed in the hope that it will be useful, * |
| 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of * |
| 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * |
| 14 | * GNU General Public License for more details. * |
| 15 | * * |
| 16 | * You should have received a copy of the GNU General Public License * |
| 17 | * along with this program; if not, see <http://www.gnu.org/licenses/> * |
| 18 | * or write to the Free Software Foundation, Inc., * |
| 19 | * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * |
| 20 | ***************************************************************************/ |
| 21 | #ifndef LOGIN_H |
| 22 | #define LOGIN_Hcxx . . $ `src/network/login.h:22:9`! |
| 23 | |
| 24 | #include <QDialog> |
| 25 | #include <QAbstractTableModel> |
| 26 | #include <QAction> |
| 27 | #include <QMenu> |
| 28 | #include <QStyledItemDelegate> |
| 29 | #include "ui_login.h"cxx . . $ `<file>/build/ui/ui_login.h`/ |
| 30 | #include "defines.h"cxx . . $ `<file>/src/defines.h`/ |
| 31 | #include "networkconnection.h"cxx . . $ `<file>/src/network/networkconnection.h`/ |
| 32 | |
| 33 | class NetworkConnectioncxx . . $ NetworkConnection#; |
| 34 | class QMessageBoxcxx . . $ QMessageBox#; |
| 35 | |
| 36 | class CredentialTableModelcxx . . $ CredentialTableModel# : public QAbstractTableModelcxx . . $ QAbstractTableModel# |
| 37 | { |
| 38 | Q_OBJECTcxx . . $ CredentialTableModel#tr(75d9f1c324b4579d). |
| 39 | public: |
| 40 | CredentialTableModelcxx . . $ CredentialTableModel#CredentialTableModel(749de1b6ae65bddd).(QObjectcxx . . $ QObject# * parent = 0); |
| 41 | ~cxx . . $ CredentialTableModel#`~CredentialTableModel`(ced63f7c635d850d).CredentialTableModelcxx . . $ CredentialTableModel#(); |
| 42 | int rowCountcxx . . $ CredentialTableModel#rowCount(e3878d4d6cd9529c).(const QModelIndexcxx . . $ QModelIndex# & parent = QModelIndexcxx . . $ QModelIndex#QModelIndex(ced63f7c635d850d).()) const; |
| 43 | int columnCountcxx . . $ CredentialTableModel#columnCount(e3878d4d6cd9529c).(const QModelIndexcxx . . $ QModelIndex# & parent = QModelIndexcxx . . $ QModelIndex#QModelIndex(ced63f7c635d850d).()) const; |
| 44 | QModelIndexcxx . . $ QModelIndex# indexcxx . . $ CredentialTableModel#index(37dbccf64c4e392). ( int row, int column, const QModelIndexcxx . . $ QModelIndex# & parent = QModelIndexcxx . . $ QModelIndex#QModelIndex(ced63f7c635d850d).() ) const; |
| 45 | QVariantcxx . . $ QVariant# datacxx . . $ CredentialTableModel#data(69b5b18a001c0029).(const QModelIndexcxx . . $ QModelIndex# & index, int role) const; |
| 46 | QVariantcxx . . $ QVariant# headerDatacxx . . $ CredentialTableModel#headerData(b8cfec0985494997).(int section, Qtcxx . . $ Qt/::Orientationcxx . . $ Qt/Orientation# orientation, int role) const; |
| 47 | Qtcxx . . $ Qt/::ItemFlagscxx . . $ Qt/ItemFlags# flagscxx . . $ CredentialTableModel#flags(36b38c1b3d3f7b45).(const QModelIndexcxx . . $ QModelIndex# & index) const; |
| 48 | bool setDatacxx . . $ CredentialTableModel#setData(6d1d8401440d0a2c).(const QModelIndexcxx . . $ QModelIndex# & index, const QVariantcxx . . $ QVariant# & value, int role = Qtcxx . . $ Qt/::EditRolecxx . . $ Qt/EditRole.); |
| 49 | bool removeRowscxx . . $ CredentialTableModel#removeRows(c4e00837c4ba3150).(int row, int count, const QModelIndexcxx . . $ QModelIndex# &parent); |
| 50 | |
| 51 | void addCredentialcxx . . $ CredentialTableModel#addCredential(231cf4fc7da7cd6f).(ConnectionCredentialscxx . . $ ConnectionCredentials# cred); |
| 52 | void loadCredentialscxx . . $ CredentialTableModel#loadCredentials(49f6e7a06ebc5aa8).(void); |
| 53 | void saveCredentialscxx . . $ CredentialTableModel#saveCredentials(49f6e7a06ebc5aa8).(void); |
| 54 | public: |
| 55 | QListcxx . . $ QList# <ConnectionCredentialscxx . . $ ConnectionCredentials#> credentialscxx . . $ CredentialTableModel#credentials.; |
| 56 | bool editablecxx . . $ CredentialTableModel#editable.; |
| 57 | }; |
| 58 | |
| 59 | class ComboBoxDelegatecxx . . $ ComboBoxDelegate# : public QStyledItemDelegatecxx . . $ QStyledItemDelegate# |
| 60 | { |
| 61 | Q_OBJECTcxx . . $ `<external>/1208926524888476972/qobjectdefs.h:170:9`! |
| 62 | public: |
| 63 | ComboBoxDelegatecxx . . $ ComboBoxDelegate#ComboBoxDelegate(749de1b6ae65bddd).(QObjectcxx . . $ QObject# *parent = 0); |
| 64 | |
| 65 | QWidgetcxx . . $ QWidget# *createEditorcxx . . $ ComboBoxDelegate#createEditor(f2c7e294f1841167).(QWidgetcxx . . $ QWidget# *parent, const QStyleOptionViewItemcxx . . $ QStyleOptionViewItem# &option, |
| 66 | const QModelIndexcxx . . $ QModelIndex# &index) const; |
| 67 | |
| 68 | void setEditorDatacxx . . $ ComboBoxDelegate#setEditorData(bb3f73f852642966).(QWidgetcxx . . $ QWidget# *editor, const QModelIndexcxx . . $ QModelIndex# &index) const; |
| 69 | void setModelDatacxx . . $ ComboBoxDelegate#setModelData(3e66fac4f8e72d1b).(QWidgetcxx . . $ QWidget# *editor, QAbstractItemModelcxx . . $ QAbstractItemModel# *model, |
| 70 | const QModelIndexcxx . . $ QModelIndex# &index) const; |
| 71 | |
| 72 | void updateEditorGeometrycxx . . $ ComboBoxDelegate#updateEditorGeometry(8e076d6424181c8e).(QWidgetcxx . . $ QWidget# *editor, |
| 73 | const QStyleOptionViewItemcxx . . $ QStyleOptionViewItem# &option, const QModelIndexcxx . . $ QModelIndex# &index) const; |
| 74 | }; |
| 75 | |
| 76 | class NewCredentialsActioncxx . . $ NewCredentialsAction# : public QActioncxx . . $ QAction# |
| 77 | { |
| 78 | Q_OBJECTcxx . . $ QMetaObject#Call# |
| 79 | public: |
| 80 | NewCredentialsActioncxx . . $ NewCredentialsAction#NewCredentialsAction(20f9cc7f6c64474b).(const QStringcxx . . $ QString# &text, ConnectionCredentialscxx . . $ ConnectionCredentials# c, QObjectcxx . . $ QObject# * parent = 0) : QActioncxx . . $ QAction#QAction(6b24f83d17022bd9).(text,parent), credcxx . . $ NewCredentialsAction#cred.(c) {}; |
| 81 | ConnectionCredentialscxx . . $ ConnectionCredentials# credcxx . . $ NewCredentialsAction#cred.; |
| 82 | }; |
| 83 | |
| 84 | class LoginDialogcxx . . $ LoginDialog# : public QDialogcxx . . $ QDialog#, Uicxx . . $ Ui/::LoginDialogcxx . . $ Ui/LoginDialog# |
| 85 | { |
| 86 | Q_OBJECTcxx . . $ LoginDialog#staticMetaObject. |
| 87 | public: |
| 88 | LoginDialogcxx . . $ LoginDialog#LoginDialog(108f35f7aa7f3cf9).(QWidgetcxx . . $ QWidget# *parent = 0); |
| 89 | ~cxx . . $ LoginDialog#`~LoginDialog`(ced63f7c635d850d).LoginDialogcxx . . $ LoginDialog#(); |
| 90 | private: |
| 91 | void slot_cancelcxx . . $ LoginDialog#slot_cancel(49f6e7a06ebc5aa8).(void); |
| 92 | void slot_connectcxx . . $ LoginDialog#slot_connect(58b98458fece0954).(QModelIndexcxx . . $ QModelIndex#); |
| 93 | void slot_newCredentialcxx . . $ LoginDialog#slot_newCredential(92b1e80c0a7f1406).(QActioncxx . . $ QAction# *action); |
| 94 | void slot_deleteCredentialcxx . . $ LoginDialog#slot_deleteCredential(49f6e7a06ebc5aa8).(void); |
| 95 | void slot_receiveConnectionStatecxx . . $ LoginDialog#slot_receiveConnectionState(41e728cff2b23034).(ConnectionStatecxx . . $ ConnectionState# newState); |
| 96 | void slot_showPopupcxx . . $ LoginDialog#slot_showPopup(4f9e9534be445c03).(const QPointcxx . . $ QPoint# & iPoint); |
| 97 | void slot_toggleEditablecxx . . $ LoginDialog#slot_toggleEditable(49f6e7a06ebc5aa8).(void); |
| 98 | |
| 99 | ConnectionTypecxx . . $ ConnectionType# serverStringToConnectionTypecxx . . $ LoginDialog#serverStringToConnectionType(50c227e215ead0ad).(const QStringcxx . . $ QString# & s); |
| 100 | NetworkConnectioncxx . . $ NetworkConnection# * newConnectioncxx . . $ LoginDialog#newConnection(e6435401577aa8ae).(ConnectionCredentialscxx . . $ ConnectionCredentials# cred); |
| 101 | Uicxx . . $ Ui/::LoginDialogcxx . . $ Ui/LoginDialog# uicxx . . $ LoginDialog#ui.; |
| 102 | NetworkConnectioncxx . . $ NetworkConnection# * connectioncxx . . $ LoginDialog#connection.; |
| 103 | CredentialTableModelcxx . . $ CredentialTableModel# * credModelcxx . . $ LoginDialog#credModel.; |
| 104 | QMenucxx . . $ QMenu# * newCredMenucxx . . $ LoginDialog#newCredMenu.; |
| 105 | QModelIndexcxx . . $ QModelIndex# popup_itemcxx . . $ LoginDialog#popup_item.; |
| 106 | }; |
| 107 | |
| 108 | #endif |