Debian Codegraph @

src/qt6-im/hime-qt.cpp

raw
1 /*
2 * Copyright (C) 2022 The HIME team, Taiwan
3 *
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; version 2 of the License.
7 *
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * You should have received a copy of the GNU General Public License along
14 * with this program; if not, write to the Free Software Foundation, Inc.,
15 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
16 */
17
18 #include "../util.h"
19 #include "hime-qt.h"
20 #include <cstdio>
21
22 #define HIMEID "hime"
23
24 QStringList QHimePlatformInputContextPlugin::keys () const {
25 dbg ("QStringList QHimePlatformInputContextPlugin::keys()\n");
26 return QStringList (QStringLiteral (HIMEID));
27 }
28
29 QHimePlatformInputContext *QHimePlatformInputContextPlugin::create (const QString &system, const QStringList &paramList) {
30 Q_UNUSED (paramList);
31 dbg ("QHimePlatformInputContextPlugin::create()\n");
32
33 if (system.compare (system, QStringLiteral (HIMEID), Qt::CaseInsensitive) == 0)
34 return new QHimePlatformInputContext;
35 return 0;
36 }