Changeset View
Changeset View
Standalone View
Standalone View
kcm/src/utils.cpp
Show First 20 Lines • Show All 42 Lines • ▼ Show 20 Line(s) | 40 | if (output->edid()) { | |||
---|---|---|---|---|---|
43 | QString name; | 43 | QString name; | ||
44 | if (!(output->edid()->vendor().isEmpty())) { | 44 | if (!(output->edid()->vendor().isEmpty())) { | ||
45 | name = output->edid()->vendor() + QLatin1Char(' '); | 45 | name = output->edid()->vendor() + QLatin1Char(' '); | ||
46 | } | 46 | } | ||
47 | if (!output->edid()->name().isEmpty()) { | 47 | if (!output->edid()->name().isEmpty()) { | ||
48 | name += output->edid()->name() + QLatin1Char(' '); | 48 | name += output->edid()->name() + QLatin1Char(' '); | ||
49 | } | 49 | } | ||
50 | if (!name.trimmed().isEmpty()) { | 50 | if (!name.trimmed().isEmpty()) { | ||
51 | return name + QStringLiteral("(%1)").arg(output->name()); | 51 | return name + QLatin1Char('(') + output->name() + QLatin1Char(')'); | ||
52 | } | 52 | } | ||
53 | } | 53 | } | ||
54 | return output->name(); | 54 | return output->name(); | ||
55 | } | 55 | } | ||
56 | 56 | | |||
57 | QString Utils::sizeToString(const QSize &size) | 57 | QString Utils::sizeToString(const QSize &size) | ||
58 | { | 58 | { | ||
59 | return QStringLiteral("%1x%2").arg(size.width()).arg(size.height()); | 59 | return QStringLiteral("%1x%2").arg(size.width()).arg(size.height()); | ||
60 | } | 60 | } | ||
61 | 61 | |