phonesettings/cpphonesettingsplugins/callsplugin/src/cpcallsplugingroup.h
changeset 37 ba76fc04e6c2
child 45 6b911d05207e
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/phonesettings/cpphonesettingsplugins/callsplugin/src/cpcallsplugingroup.h	Fri Jun 04 10:19:18 2010 +0100
@@ -0,0 +1,109 @@
+/*
+ * Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
+ * All rights reserved.
+ * This component and the accompanying materials are made available
+ * under the terms of "Eclipse Public License v1.0"
+ * which accompanies this distribution, and is available
+ * at the URL "http://www.eclipse.org/legal/epl-v10.html".
+ *
+ * Initial Contributors:
+ * Nokia Corporation - initial contribution.
+ *
+ * Contributors:
+ *
+ * Description:  
+ *
+ */
+#ifndef CPCALLSPLUGINGROUP_H
+#define CPCALLSPLUGINGROUP_H
+
+#include <QObject>
+#include <QMap>
+#include <QVariant>
+#include <hbmessagebox.h>
+#include <cpsettingformitemdata.h>
+#include <psetcallwaitingwrapper.h>
+
+class HbDataFormModel;
+class HbDataFormModelItem; 
+class HbLineEdit;
+class PSetWrapper;
+class PSetCliWrapper; 
+class SsSettingsWrapper; 
+class PSetCallWaitingWrapper;
+class CpSettingsWrapper;
+
+class CpCallsPluginGroup: public CpSettingFormItemData
+{
+    Q_OBJECT
+
+public:
+
+    explicit CpCallsPluginGroup(CpItemDataHelper &helper);
+
+    ~CpCallsPluginGroup();
+    
+private:     
+    
+    void createShowCallDurationItem();
+    void createSoftRejectItem();
+    void createCLIItem();
+    void createCallWaitingtem();
+    
+    void connectShowCallDurationItem();
+    void connectSoftRejectItem();
+    void connectCLIItem();
+    void connectCallWaitingItem();
+    
+    void insertMappedListItems(); 
+    
+public slots:
+    
+    void showCallDurationStateChanged();
+    void softRejectTextChanged();
+    void callWaitingCurrentIndexChanged();
+    void cliCurrentIndexChanged(int index);
+    
+    // Call waiting slots
+    void handleCallWaitingGetStatus( 
+        PSetCallWaitingWrapper::PsCallWaitingStatus status,
+        const QList<unsigned char> &basicServiceGroupIds);
+    void handleCallWaitingChanged( 
+        PSetCallWaitingWrapper::PsCallWaitingCommand setting,
+        int aResult );
+    void handleCallWaitingRequesting( bool ongoing, bool interrupted ); 
+    void handleCallWaitingError( int error );
+    
+signals:
+    
+    void showGlobalProgressNote(int &noteId, const QString& text);
+    void showGlobalNote(
+        int &noteId, const QString& text, HbMessageBox::MessageBoxType);
+    void showGlobalErrorNote(int &noteId, int errorCode);
+    void cancelNote(int noteId);
+    
+private:   
+
+    // Setting wrappers 
+    PSetWrapper *m_pSetWrapper; 
+    SsSettingsWrapper *m_ssSettingsWrapper; 
+    CpSettingsWrapper *m_cpSettingsWrapper;
+
+    // Not own
+    PSetCliWrapper* m_cliWrapper;
+    PSetCallWaitingWrapper* m_callWaitingWrapper;
+    
+    // Not owned objects
+    CpSettingFormItemData *m_DataItemShowCallDuration; 
+    CpSettingFormItemData *m_DataItemSoftRejectTextEditor;
+    CpSettingFormItemData *m_DataItemCLI; 
+    CpSettingFormItemData *m_DataItemCallWaiting;
+    
+    // List data mappings 
+    QMap<int, QString> m_cliSettingMap;
+    
+    bool m_callWaitingDistinguishEnabled;
+    int m_activeNoteId;
+    CpItemDataHelper &m_helper;
+};
+#endif // CPCALLSPLUGINGROUP_H