phoneplugins/phoneindicatorplugin/inc/phoneindicators.h
branchGCC_SURGE
changeset 51 f39ed5e045e0
parent 30 ebdbd102c78a
parent 46 bc5a64e5bc3c
equal deleted inserted replaced
40:bab96b7ed1a4 51:f39ed5e045e0
    21 #include <hbindicatorinterface.h>
    21 #include <hbindicatorinterface.h>
    22 #include <QObject>
    22 #include <QObject>
    23 #include <QString>
    23 #include <QString>
    24 
    24 
    25 
    25 
    26 static const char *IndicatorNameTemplate = "PhoneIndicator_%1";
    26 static const char *IndicatorNameTemplate = "com.nokia.symbian.phoneindicatorplugin_%1";
    27 
    27 
    28 enum Interaction
    28 enum Interaction
    29 {
    29 {
    30     InteractionNone,
    30     InteractionNone,
    31     OpenMissedCallView,
    31     OpenMissedCallView,
    32     SwitchBackToCall,
    32     OpenCallUi,
       
    33     OpenDiverSettingsView,
    33     Deactivate
    34     Deactivate
    34 };
    35 };
    35 
    36 
    36 enum PhoneIndicatorTypes
    37 enum PhoneIndicatorTypes
    37 {
    38 {
    38     PhoneMissedCallIndicator = 0,
    39     PhoneMissedCallIndicator = 0,
    39     PhoneActiveCallIndicator
    40     PhoneActiveCallIndicator,
       
    41     PhoneDivertIndidicator
    40 };
    42 };
    41 
    43 
    42 inline QString indicatorName(int indicatorType) {
    44 inline QString indicatorName(int indicatorType) {
    43     return QString(IndicatorNameTemplate).arg(indicatorType);
    45     return QString(IndicatorNameTemplate).arg(indicatorType);
    44 }
    46 }
    51     Interaction interaction;
    53     Interaction interaction;
    52 };
    54 };
    53 
    55 
    54 Q_DECLARE_METATYPE(PhoneIndicatorInfo)
    56 Q_DECLARE_METATYPE(PhoneIndicatorInfo)
    55 
    57 
    56 static const int PhoneIndicatorCount = 2;
    58 static const int PhoneIndicatorCount = 3;
    57 static const PhoneIndicatorInfo IndicatorInfos[PhoneIndicatorCount] = {
    59 static const PhoneIndicatorInfo IndicatorInfos[PhoneIndicatorCount] = {
    58     {"qtg_mono_info.svg",   "Missed call", "Name/Number", OpenMissedCallView },
    60     {"qtg_mono_info.svg",   "Missed call", "Name/Number", OpenMissedCallView },
    59     {"qtg_mono_info.svg",   "Active call", " ", SwitchBackToCall }
    61     {"qtg_mono_info.svg",   "Active call", " ", OpenCallUi },
       
    62     {"qtg_mono_info.svg",   "Active diverts", " ", OpenDiverSettingsView }
    60 };
    63 };
    61 
    64 
    62 #endif // PHONEINDICATORS_H
    65 #endif // PHONEINDICATORS_H