56 // |
56 // |
57 // --------------------------------------------------------------------------- |
57 // --------------------------------------------------------------------------- |
58 // |
58 // |
59 QInputContext* HbHardwareInputPlugin::create(const QString& key) |
59 QInputContext* HbHardwareInputPlugin::create(const QString& key) |
60 { |
60 { |
61 if (key == QString("HbHardware12key")) { |
61 if (key == QString("HbHardware12key")) { |
62 return new HbHardware12key(); |
62 return new HbHardware12key(); |
63 } else if (key == QString("HbHardwareQwerty")) { |
63 } else if (key == QString("HbHardwareQwerty")) { |
64 return new HbHardwareQwerty(); |
64 return new HbHardwareQwerty(); |
65 } else { |
65 } else { |
66 return 0; |
66 return 0; |
67 } |
67 } |
68 } |
68 } |
69 |
69 |
70 // --------------------------------------------------------------------------- |
70 // --------------------------------------------------------------------------- |
71 // HbHardwareInputPlugin::description |
71 // HbHardwareInputPlugin::description |
72 // |
72 // |
73 // --------------------------------------------------------------------------- |
73 // --------------------------------------------------------------------------- |
74 // |
74 // |
75 QString HbHardwareInputPlugin::description(const QString& key) |
75 QString HbHardwareInputPlugin::description(const QString& key) |
76 { |
76 { |
77 if (key == QString("HbHardware12key")) { |
77 if (key == QString("HbHardware12key")) { |
78 return QString("HW phone keypad input"); |
78 return QString("HW phone keypad input"); |
79 } else if (key == QString("HbHardwareQwerty")) { |
79 } else if (key == QString("HbHardwareQwerty")) { |
80 return QString("HW phone Qwerty keypad input"); |
80 return QString("HW phone Qwerty keypad input"); |
81 } else { |
81 } else { |
82 return QString(""); |
82 return QString(""); |
83 } |
83 } |
84 } |
84 } |
85 |
85 |
86 // --------------------------------------------------------------------------- |
86 // --------------------------------------------------------------------------- |
87 // HbHardwareInputPlugin::displayName |
87 // HbHardwareInputPlugin::displayName |
88 // |
88 // |
89 // --------------------------------------------------------------------------- |
89 // --------------------------------------------------------------------------- |
90 // |
90 // |
91 QString HbHardwareInputPlugin::displayName(const QString& key) |
91 QString HbHardwareInputPlugin::displayName(const QString& key) |
92 { |
92 { |
93 if (key == QString("HbHardware12key")) { |
93 if (key == QString("HbHardware12key")) { |
94 return QString("HW 12-key"); |
94 return QString("HW 12-key"); |
95 } else if (key == QString("HbHardwareQwerty")) { |
95 } else if (key == QString("HbHardwareQwerty")) { |
96 return QString("HW phone Qwerty keypad input"); |
96 return QString("HW phone Qwerty keypad input"); |
97 } else { |
97 } else { |
98 return QString(""); |
98 return QString(""); |
99 } |
99 } |
100 } |
100 } |
101 |
101 |
102 // --------------------------------------------------------------------------- |
102 // --------------------------------------------------------------------------- |
103 // HbHardwareInputPlugin::keys |
103 // HbHardwareInputPlugin::keys |
104 // |
104 // |
105 // --------------------------------------------------------------------------- |
105 // --------------------------------------------------------------------------- |
106 // |
106 // |
107 QStringList HbHardwareInputPlugin::keys() const |
107 QStringList HbHardwareInputPlugin::keys() const |
108 { |
108 { |
109 QStringList keys; |
109 QStringList keys; |
110 keys.append(QString("HbHardware12key")); |
110 keys.append(QString("HbHardware12key")); |
111 keys.append(QString("HbHardwareQwerty")); |
111 keys.append(QString("HbHardwareQwerty")); |
112 return keys; |
112 return keys; |
113 } |
113 } |
114 |
114 |
115 // --------------------------------------------------------------------------- |
115 // --------------------------------------------------------------------------- |
116 // HbHardwareInputPlugin::languages |
116 // HbHardwareInputPlugin::languages |
117 // |
117 // |
118 // --------------------------------------------------------------------------- |
118 // --------------------------------------------------------------------------- |
119 // |
119 // |
120 QStringList HbHardwareInputPlugin::languages(const QString& /*key*/) |
120 QStringList HbHardwareInputPlugin::languages(const QString& /*key*/) |
121 { |
121 { |
122 return QStringList(); |
122 return QStringList(); |
123 } |
123 } |
124 |
124 |
125 // |
125 // |
126 // Make plugin loadable. |
126 // Make plugin loadable. |
127 // |
127 // |