Add 'and' to typing display

remotes/origin/0.7.0-dev
Nicolas Werner 5 years ago
parent b28115eb37
commit 0398c846f6
  1. 17
      resources/langs/nheko_de.ts
  2. 17
      resources/langs/nheko_el.ts
  3. 17
      resources/langs/nheko_en.ts
  4. 17
      resources/langs/nheko_fi.ts
  5. 17
      resources/langs/nheko_fr.ts
  6. 17
      resources/langs/nheko_nl.ts
  7. 18
      resources/langs/nheko_pl.ts
  8. 18
      resources/langs/nheko_ru.ts
  9. 16
      resources/langs/nheko_zh_CN.ts
  10. 17
      src/TypingDisplay.cpp
  11. 2
      src/timeline/TimelineItem.h

@ -494,15 +494,14 @@
</context>
<context>
<name>TypingDisplay</name>
<message>
<location filename="../../src/TypingDisplay.cpp" line="+46"/>
<source> is typing</source>
<translation> tippt</translation>
</message>
<message>
<location line="+2"/>
<source> are typing</source>
<translation> tippen</translation>
<message numerus="yes">
<location filename="../../src/TypingDisplay.cpp" line="+37"/>
<source>%1 and %2 are typing</source>
<comment>Multiple users are typing. First argument is a comma separated list of potentially multiple users. Second argument is the last user of that list. (If only one user is typing, %1 is empty. You should still use it in your string though to silence Qt warnings.)</comment>
<translation>
<numerusform>%1%2 tippt</numerusform>
<numerusform>%1 und %2 tippen</numerusform>
</translation>
</message>
</context>
<context>

@ -494,15 +494,14 @@
</context>
<context>
<name>TypingDisplay</name>
<message>
<location filename="../../src/TypingDisplay.cpp" line="+46"/>
<source> is typing</source>
<translation> πληκτρολογεί</translation>
</message>
<message>
<location line="+2"/>
<source> are typing</source>
<translation> πληκτρολογούν</translation>
<message numerus="yes">
<location filename="../../src/TypingDisplay.cpp" line="+37"/>
<source>%1 and %2 are typing</source>
<comment>Multiple users are typing. First argument is a comma separated list of potentially multiple users. Second argument is the last user of that list. (If only one user is typing, %1 is empty. You should still use it in your string though to silence Qt warnings.)</comment>
<translation type="unfinished">
<numerusform></numerusform>
<numerusform></numerusform>
</translation>
</message>
</context>
<context>

@ -494,15 +494,14 @@
</context>
<context>
<name>TypingDisplay</name>
<message>
<location filename="../../src/TypingDisplay.cpp" line="+46"/>
<source> is typing</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+2"/>
<source> are typing</source>
<translation type="unfinished"></translation>
<message numerus="yes">
<location filename="../../src/TypingDisplay.cpp" line="+37"/>
<source>%1 and %2 are typing</source>
<comment>Multiple users are typing. First argument is a comma separated list of potentially multiple users. Second argument is the last user of that list. (If only one user is typing, %1 is empty. You should still use it in your string though to silence Qt warnings.)</comment>
<translation>
<numerusform>%1%2 is typing</numerusform>
<numerusform>%1 and %2 are typing</numerusform>
</translation>
</message>
</context>
<context>

@ -494,15 +494,14 @@
</context>
<context>
<name>TypingDisplay</name>
<message>
<location filename="../../src/TypingDisplay.cpp" line="+46"/>
<source> is typing</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+2"/>
<source> are typing</source>
<translation type="unfinished"></translation>
<message numerus="yes">
<location filename="../../src/TypingDisplay.cpp" line="+37"/>
<source>%1 and %2 are typing</source>
<comment>Multiple users are typing. First argument is a comma separated list of potentially multiple users. Second argument is the last user of that list. (If only one user is typing, %1 is empty. You should still use it in your string though to silence Qt warnings.)</comment>
<translation type="unfinished">
<numerusform></numerusform>
<numerusform></numerusform>
</translation>
</message>
</context>
<context>

@ -495,15 +495,14 @@
</context>
<context>
<name>TypingDisplay</name>
<message>
<location filename="../../src/TypingDisplay.cpp" line="+46"/>
<source> is typing</source>
<translation> est en train d&apos;écrire</translation>
</message>
<message>
<location line="+2"/>
<source> are typing</source>
<translation> sont en train d&apos;écrire</translation>
<message numerus="yes">
<location filename="../../src/TypingDisplay.cpp" line="+37"/>
<source>%1 and %2 are typing</source>
<comment>Multiple users are typing. First argument is a comma separated list of potentially multiple users. Second argument is the last user of that list. (If only one user is typing, %1 is empty. You should still use it in your string though to silence Qt warnings.)</comment>
<translation type="unfinished">
<numerusform></numerusform>
<numerusform></numerusform>
</translation>
</message>
</context>
<context>

@ -494,15 +494,14 @@
</context>
<context>
<name>TypingDisplay</name>
<message>
<location filename="../../src/TypingDisplay.cpp" line="+46"/>
<source> is typing</source>
<translation> is aan het typen</translation>
</message>
<message>
<location line="+2"/>
<source> are typing</source>
<translation> zijn aan het typen</translation>
<message numerus="yes">
<location filename="../../src/TypingDisplay.cpp" line="+37"/>
<source>%1 and %2 are typing</source>
<comment>Multiple users are typing. First argument is a comma separated list of potentially multiple users. Second argument is the last user of that list. (If only one user is typing, %1 is empty. You should still use it in your string though to silence Qt warnings.)</comment>
<translation type="unfinished">
<numerusform></numerusform>
<numerusform></numerusform>
</translation>
</message>
</context>
<context>

@ -494,15 +494,15 @@
</context>
<context>
<name>TypingDisplay</name>
<message>
<location filename="../../src/TypingDisplay.cpp" line="+46"/>
<source> is typing</source>
<translation> pisze</translation>
</message>
<message>
<location line="+2"/>
<source> are typing</source>
<translation> piszą</translation>
<message numerus="yes">
<location filename="../../src/TypingDisplay.cpp" line="+37"/>
<source>%1 and %2 are typing</source>
<comment>Multiple users are typing. First argument is a comma separated list of potentially multiple users. Second argument is the last user of that list. (If only one user is typing, %1 is empty. You should still use it in your string though to silence Qt warnings.)</comment>
<translation type="unfinished">
<numerusform></numerusform>
<numerusform></numerusform>
<numerusform></numerusform>
</translation>
</message>
</context>
<context>

@ -494,15 +494,15 @@
</context>
<context>
<name>TypingDisplay</name>
<message>
<location filename="../../src/TypingDisplay.cpp" line="+46"/>
<source> is typing</source>
<translation> печатает</translation>
</message>
<message>
<location line="+2"/>
<source> are typing</source>
<translation> печатают</translation>
<message numerus="yes">
<location filename="../../src/TypingDisplay.cpp" line="+37"/>
<source>%1 and %2 are typing</source>
<comment>Multiple users are typing. First argument is a comma separated list of potentially multiple users. Second argument is the last user of that list. (If only one user is typing, %1 is empty. You should still use it in your string though to silence Qt warnings.)</comment>
<translation type="unfinished">
<numerusform></numerusform>
<numerusform></numerusform>
<numerusform></numerusform>
</translation>
</message>
</context>
<context>

@ -494,15 +494,13 @@
</context>
<context>
<name>TypingDisplay</name>
<message>
<location filename="../../src/TypingDisplay.cpp" line="+46"/>
<source> is typing</source>
<translation> </translation>
</message>
<message>
<location line="+2"/>
<source> are typing</source>
<translation> </translation>
<message numerus="yes">
<location filename="../../src/TypingDisplay.cpp" line="+37"/>
<source>%1 and %2 are typing</source>
<comment>Multiple users are typing. First argument is a comma separated list of potentially multiple users. Second argument is the last user of that list. (If only one user is typing, %1 is empty. You should still use it in your string though to silence Qt warnings.)</comment>
<translation type="unfinished">
<numerusform></numerusform>
</translation>
</message>
</context>
<context>

@ -33,6 +33,14 @@ TypingDisplay::setUsers(const QStringList &uid)
text_.clear();
QString temp = text_ +=
tr("%1 and %2 are typing",
"Multiple users are typing. First argument is a comma separated list of potentially "
"multiple users. Second argument is the last user of that list. (If only one user is "
"typing, %1 is empty. You should still use it in your string though to silence Qt "
"warnings.)",
uid.size());
if (uid.isEmpty()) {
hide();
update();
@ -40,12 +48,9 @@ TypingDisplay::setUsers(const QStringList &uid)
return;
}
text_ = uid.join(", ");
if (uid.size() == 1)
text_ += tr(" is typing");
else if (uid.size() > 1)
text_ += tr(" are typing");
QStringList uidWithoutLast = uid;
uidWithoutLast.pop_back();
text_ = temp.arg(uidWithoutLast.join(", ")).arg(uid.back());
show();
update();

@ -277,7 +277,7 @@ private:
QFutureWatcher<QString> *colorGenerating_;
QString event_id_;
mtx::events::MessageType message_type_ = mtx::events::MessageType::Unknown;
mtx::events::MessageType message_type_ = mtx::events::MessageType::Unknown;
QString room_id_;
DescInfo descriptionMsg_;

Loading…
Cancel
Save