telutils/dialpad/src/dialpadbutton.cpp
changeset 15 d7fc66ccd6fb
parent 12 ae8abd0db65c
child 19 e44a8c097b15
equal deleted inserted replaced
13:e32024264ebb 15:d7fc66ccd6fb
    22 #include <hbevent.h>
    22 #include <hbevent.h>
    23 
    23 
    24 #include "dialpadbutton.h"
    24 #include "dialpadbutton.h"
    25 
    25 
    26 DialpadButton::DialpadButton(QGraphicsItem *parent)
    26 DialpadButton::DialpadButton(QGraphicsItem *parent)
    27     : HbPushButton(parent)
    27     : HbPushButton(parent), mButtonType(NumericButton)
    28 {
    28 {
    29 }
    29 }
    30 
    30 
    31 DialpadButton::~DialpadButton()
    31 DialpadButton::~DialpadButton()
    32 {
    32 {
       
    33 }
       
    34 
       
    35 DialpadButton::DialpadButtonType DialpadButton::buttonType() const
       
    36 {
       
    37     return mButtonType;
       
    38 }
       
    39 
       
    40 void DialpadButton::setButtonType(DialpadButtonType type)
       
    41 {
       
    42     mButtonType = type;
    33 }
    43 }
    34 
    44 
    35 void DialpadButton::changeEvent(QEvent *event)
    45 void DialpadButton::changeEvent(QEvent *event)
    36 {
    46 {
    37     if (event->type() == HbEvent::ThemeChanged) {
    47     if (event->type() == HbEvent::ThemeChanged) {
    58     }
    68     }
    59 
    69 
    60     return result;
    70     return result;
    61 }
    71 }
    62 
    72 
       
    73 void DialpadButton::polish(HbStyleParameters& params)
       
    74 {
       
    75     // HbPushButton::polish() prevents layouting
       
    76     // text and additional-text horizontally.
       
    77     HbAbstractButton::polish( params );
       
    78 }
    63 
    79