diff --git a/SMSGui.ui b/SMSGui.ui
index 5531808..d77b938 100644
--- a/SMSGui.ui
+++ b/SMSGui.ui
@@ -19,117 +19,106 @@
Form
-
-
-
- 0
- 160
- 481
- 451
-
-
-
-
-
-
- 0
- 620
- 521
- 121
-
-
-
- QFrame::StyledPanel
-
-
- QFrame::Raised
-
-
- -
-
+
+
-
+
+
+
+ 0
+ 0
+
+
+
+
+ 100
+ 100
+
+
+
+
+ 100
+ 100
+
+
+
+ TextLabel
+
+
+
+ -
+
+
+ TextLabel
+
+
+
+ -
+
+
+ -
+
+
+ 2
+
+
+ false
+
+
- Send
+ 1
-
-
- -
-
-
- -
-
-
- Qt::Horizontal
-
-
-
- 40
- 20
-
-
-
-
- -
-
-
-
- 200
- 75
-
-
-
- TextLabel
-
-
-
-
-
-
-
-
- 520
- 160
- 256
- 471
-
-
-
- 2
-
-
- false
-
-
-
- 1
-
-
-
-
-
-
- 10
- 10
- 141
- 121
-
-
-
- TextLabel
-
-
-
-
-
- 180
- 20
- 591
- 101
-
-
-
- TextLabel
-
-
+
+
+
+ -
+
+
+ QFrame::StyledPanel
+
+
+ QFrame::Raised
+
+
+
-
+
+
+ Send
+
+
+
+ -
+
+
+ -
+
+
+ Qt::Horizontal
+
+
+
+ 40
+ 20
+
+
+
+
+ -
+
+
+
+ 200
+ 75
+
+
+
+ TextLabel
+
+
+
+
+
+
+
diff --git a/Sources/SMSClient/SMSClient.cpp b/Sources/SMSClient/SMSClient.cpp
index 5c1d96f..250a106 100644
--- a/Sources/SMSClient/SMSClient.cpp
+++ b/Sources/SMSClient/SMSClient.cpp
@@ -45,8 +45,6 @@ int CSMSClient::SetAllMsgsDatabase(QString DID, QList *MessagesList
if(mSMSDatabase.SetAllMessages(DID,MessagesList) == RET_OK)
{
mGuiHandle->FullConversationsUpdate();
-// mMainPanel->mConversationsWindow->FullConversationsUpdate();
-// mMainPanel->mConversationWindow->hide();
}
return RET_OK;
}
@@ -70,60 +68,6 @@ int CSMSClient::SetContacts(QList *ContactsList)
return RET_OK;
}
-//unsigned int CSMSClient::QuitApplicationRequest()
-//{
-
-// QApplication::exit(69);
-// return RET_OK;
-//}
-
-//unsigned int CSMSClient::ShowSettingsWindowRequest()
-//{
-// mSettingsWindow->show();
-// return RET_OK;
-//}
-
-//unsigned int CSMSClient::SaveSettings(CSettings *Settings)
-//{
-// CSettings toto;
-// toto = *Settings;
-// mSMSClientSettings = toto;
-// mSettingsManager.SaveSettings(&mSMSClientSettings);
-
-// return RET_OK;
-//}
-
-//unsigned int CSMSClient::SettingsWindowClosed()
-//{
-
-// return RET_OK;
-//}
-
-//int CSMSClient::AppToggle()
-//{
-//// if(mMainPanel->mConversationWindow->isVisible())
-//// {
-//// mMainPanel->mConversationWindow->hide();
-
-//// }
-//// else if(mMainPanel->mConversationsWindow->isVisible())
-//// {
-//// mMainPanel->mConversationsWindow->hide();
-//// }
-//// else
-//// {
-//// mMainPanel->mConversationsWindow->show();
-//// }
-
-// return RET_OK;
-//}
-//int CSMSClient::AppPosChanged(int NewPosX, int NewPosY)
-//{
-//// mMainPanel->mConversationsWindow->setPos(50,50);
-//// mMainPanel->mConversationWindow->setPos(50,50);
-// return RET_OK;
-//}
-
int CSMSClient::ShowConversation(QString Contact)
{
CSMSConversation* Conversation;
@@ -134,30 +78,9 @@ int CSMSClient::ShowConversation(QString Contact)
return RET_ERROR;
}
-// mMainPanel->mConversationWindow->SetConversation(Conversation);
-
-// mMainPanel->mConversationsWindow->hide();
-// mMainPanel->mConversationWindow->show();
-
return RET_OK;
}
-//int CSMSClient::CloseConversationsWindow()
-//{
-//// mMainPanel->mConversationsWindow->hide();
-// return RET_OK;
-//}
-
-//int CSMSClient::CloseConversationWindow(CConversationWindow *Window)
-//{
-// Q_UNUSED(Window)
-
-//// mMainPanel->mConversationsWindow->FullConversationsUpdate();
-//// mMainPanel->mConversationWindow->hide();
-//// mMainPanel->mConversationsWindow->show();
-
-// return RET_OK;
-//}
int CSMSClient::SendSMSMessage(CSMSMessage Message)
{
@@ -167,11 +90,6 @@ int CSMSClient::SendSMSMessage(CSMSMessage Message)
int CSMSClient::NewMessageNotification(CSMSConversation *Conversation, int MessageIndex)
{
-// if(mMainPanel->mConversationWindow->NewMessageNotification(Conversation,MessageIndex) == true)
-// {
-// mSMSDatabase.SetConversationAsRead(Conversation);
-// }
- // mMainPanel->mConversationsWindow->UpdateConversation(Conversation);
mGuiHandle->NewMessageNotification(Conversation,MessageIndex);
MessageCountChangeNotification(mSMSDatabase.GetNbUnreadMsgs());
@@ -181,18 +99,12 @@ int CSMSClient::NewMessageNotification(CSMSConversation *Conversation, int Messa
int CSMSClient::SyncConversations()
{
- // mMainPanel->mConversationsWindow->FullConversationsUpdate();
return RET_OK;
}
int CSMSClient::MessageCountChangeNotification(int MsgCount)
{
- // mMainPanel->mAppIconWidget->SetNewMsgCount(MsgCount);
mTrayIconMgr->NewSMSMessagesPendingCount(MsgCount);
return RET_OK;
}
-//int CSMSClient::NewConversationAddedToDatabase(CSMSConversation *Conversation)
-//{
-
-//}
diff --git a/Sources/SMSClient/SMSClient.h b/Sources/SMSClient/SMSClient.h
index 7949d6f..7056ba2 100644
--- a/Sources/SMSClient/SMSClient.h
+++ b/Sources/SMSClient/SMSClient.h
@@ -22,10 +22,7 @@ public:
~CSMSClient();
void Start(void);
- // CSystemTrayManager *mSystemTrayManager;
- // CSettingsWindow *mSettingsWindow;
- // CProgramSettings mSettingsManager;
- //Panel *mMainPanel;
+
CSMSMasterCtrlInterface *mMasterCtrlIF;
CSMSDatabase mSMSDatabase;
CContactRepository mContactRepository;
@@ -36,17 +33,6 @@ public:
-// unsigned int QuitApplicationRequest();
-// unsigned int ShowSettingsWindowRequest();
-// unsigned int SaveSettings(CSettings *Settings);
-
-// unsigned int SettingsWindowClosed();
-
- //AppIconWidget requests
-// int AppToggle();
-// int AppPosChanged(int NewPosX, int NewPosY);
-
- //MasterCtrlIngerface Requests
int SetAllMsgsDatabase(QString DID, QList *MessagesList);
int SetDIDDatabase(QString DID);
int NewMessagesEvent(QList *MessagesList);
@@ -55,16 +41,13 @@ public:
//ConversationsWindow requests
int ShowConversation(QString Contact);
-// int CloseConversationsWindow();
//ConversationWindow requests
- //int CloseConversationWindow(CConversationWindow* Window);
int SendSMSMessage(CSMSMessage Message);
//SMSDatabase requests
int NewMessageNotification(CSMSConversation* Conversation, int MessageIndex);
- // void NewConversationAddedToDatabase(CSMSConversation *Conversation);
int SyncConversations();
int MessageCountChangeNotification(int MsgCount);
diff --git a/ui_SMSGui.h b/ui_SMSGui.h
index 7426bc7..d7f3de2 100644
--- a/ui_SMSGui.h
+++ b/ui_SMSGui.h
@@ -29,16 +29,17 @@ QT_BEGIN_NAMESPACE
class Ui_CSMSGui
{
public:
+ QGridLayout *gridLayout_2;
+ QLabel *mContactPic;
+ QLabel *mContactName;
QTextBrowser *mConversationText;
+ QTreeWidget *mContactsTreeWidget;
QFrame *mSMSEditFrame;
QGridLayout *gridLayout;
QPushButton *mSMSSendBtn;
QTextEdit *mSMSEdit;
QSpacerItem *horizontalSpacer;
QLabel *mSMSMessageStatsLabel;
- QTreeWidget *mContactsTreeWidget;
- QLabel *mContactPic;
- QLabel *mContactName;
void setupUi(QWidget *CSMSGui)
{
@@ -50,12 +51,42 @@ public:
sizePolicy.setVerticalStretch(0);
sizePolicy.setHeightForWidth(CSMSGui->sizePolicy().hasHeightForWidth());
CSMSGui->setSizePolicy(sizePolicy);
+ gridLayout_2 = new QGridLayout(CSMSGui);
+ gridLayout_2->setObjectName(QStringLiteral("gridLayout_2"));
+ mContactPic = new QLabel(CSMSGui);
+ mContactPic->setObjectName(QStringLiteral("mContactPic"));
+ QSizePolicy sizePolicy1(QSizePolicy::Fixed, QSizePolicy::Fixed);
+ sizePolicy1.setHorizontalStretch(0);
+ sizePolicy1.setVerticalStretch(0);
+ sizePolicy1.setHeightForWidth(mContactPic->sizePolicy().hasHeightForWidth());
+ mContactPic->setSizePolicy(sizePolicy1);
+ mContactPic->setMinimumSize(QSize(100, 100));
+ mContactPic->setBaseSize(QSize(100, 100));
+
+ gridLayout_2->addWidget(mContactPic, 0, 0, 1, 1);
+
+ mContactName = new QLabel(CSMSGui);
+ mContactName->setObjectName(QStringLiteral("mContactName"));
+
+ gridLayout_2->addWidget(mContactName, 0, 1, 1, 2);
+
mConversationText = new QTextBrowser(CSMSGui);
mConversationText->setObjectName(QStringLiteral("mConversationText"));
- mConversationText->setGeometry(QRect(0, 160, 481, 451));
+
+ gridLayout_2->addWidget(mConversationText, 1, 0, 1, 2);
+
+ mContactsTreeWidget = new QTreeWidget(CSMSGui);
+ QTreeWidgetItem *__qtreewidgetitem = new QTreeWidgetItem();
+ __qtreewidgetitem->setText(0, QStringLiteral("1"));
+ mContactsTreeWidget->setHeaderItem(__qtreewidgetitem);
+ mContactsTreeWidget->setObjectName(QStringLiteral("mContactsTreeWidget"));
+ mContactsTreeWidget->setIndentation(2);
+ mContactsTreeWidget->header()->setVisible(false);
+
+ gridLayout_2->addWidget(mContactsTreeWidget, 1, 2, 2, 1);
+
mSMSEditFrame = new QFrame(CSMSGui);
mSMSEditFrame->setObjectName(QStringLiteral("mSMSEditFrame"));
- mSMSEditFrame->setGeometry(QRect(0, 620, 521, 121));
mSMSEditFrame->setFrameShape(QFrame::StyledPanel);
mSMSEditFrame->setFrameShadow(QFrame::Raised);
gridLayout = new QGridLayout(mSMSEditFrame);
@@ -80,20 +111,9 @@ public:
gridLayout->addWidget(mSMSMessageStatsLabel, 2, 2, 1, 2);
- mContactsTreeWidget = new QTreeWidget(CSMSGui);
- QTreeWidgetItem *__qtreewidgetitem = new QTreeWidgetItem();
- __qtreewidgetitem->setText(0, QStringLiteral("1"));
- mContactsTreeWidget->setHeaderItem(__qtreewidgetitem);
- mContactsTreeWidget->setObjectName(QStringLiteral("mContactsTreeWidget"));
- mContactsTreeWidget->setGeometry(QRect(520, 160, 256, 471));
- mContactsTreeWidget->setIndentation(2);
- mContactsTreeWidget->header()->setVisible(false);
- mContactPic = new QLabel(CSMSGui);
- mContactPic->setObjectName(QStringLiteral("mContactPic"));
- mContactPic->setGeometry(QRect(10, 10, 141, 121));
- mContactName = new QLabel(CSMSGui);
- mContactName->setObjectName(QStringLiteral("mContactName"));
- mContactName->setGeometry(QRect(180, 20, 591, 101));
+
+ gridLayout_2->addWidget(mSMSEditFrame, 2, 0, 1, 2);
+
retranslateUi(CSMSGui);
@@ -103,10 +123,10 @@ public:
void retranslateUi(QWidget *CSMSGui)
{
CSMSGui->setWindowTitle(QApplication::translate("CSMSGui", "Form", 0));
- mSMSSendBtn->setText(QApplication::translate("CSMSGui", "Send", 0));
- mSMSMessageStatsLabel->setText(QApplication::translate("CSMSGui", "TextLabel", 0));
mContactPic->setText(QApplication::translate("CSMSGui", "TextLabel", 0));
mContactName->setText(QApplication::translate("CSMSGui", "TextLabel", 0));
+ mSMSSendBtn->setText(QApplication::translate("CSMSGui", "Send", 0));
+ mSMSMessageStatsLabel->setText(QApplication::translate("CSMSGui", "TextLabel", 0));
} // retranslateUi
};