fixed single-column msg select cancel, no 1 online in group, added korean font in linux version

This commit is contained in:
John Preston 2014-12-16 08:46:54 -08:00
parent 02657f4c6a
commit 51edfdd41d
10 changed files with 21 additions and 14 deletions

View file

@ -31,6 +31,7 @@ Source code is published under GPL v3, license is available [here](https://githu
* libogg ([BSD license](http://www.xiph.org/downloads/))
* Open Sans font ([Apache License](http://www.apache.org/licenses/LICENSE-2.0.html))
* DejaVu Sans font ([Free license](http://dejavu-fonts.org/wiki/License))
* Nanum Myeongjo font ([SIL Open Font License](http://fonts.gstatic.com/ea/nanummyeongjo/v4/OFL.txt))
###[Build instructions for Visual Studio 2013](https://github.com/telegramdesktop/tdesktop/blob/master/MSVC.md)

View file

@ -11,6 +11,5 @@ if [ ! -f "./../Linux/Release/deploy/$AppVersionStr/tsetup.$AppVersionStr.tar.xz
exit 1
fi
scp ./../Linux/Release/deploy/$AppVersionStr/tlinuxupd$AppVersion tupdates:tdesktop/static/tlinux/
scp ./../Linux/Release/deploy/$AppVersionStr/tsetup.$AppVersionStr.tar.xz tupdates:tdesktop/static/tlinux/
scp ./../Linux/Release/deploy/$AppVersionStr/tlinuxupd$AppVersion tmaster:tdesktop/www/tlinux/
scp ./../Linux/Release/deploy/$AppVersionStr/tsetup.$AppVersionStr.tar.xz tmaster:tdesktop/www/tlinux/

View file

@ -11,6 +11,6 @@ if [ ! -f "./../Linux/Release/deploy/$AppVersionStr/tsetup32.$AppVersionStr.tar.
exit 1
fi
scp ./../Linux/Release/deploy/$AppVersionStr/tlinux32upd$AppVersion tupdates:tdesktop/static/tlinux32/
scp ./../Linux/Release/deploy/$AppVersionStr/tsetup32.$AppVersionStr.tar.xz tupdates:tdesktop/static/tlinux32/
scp ./../Linux/Release/deploy/$AppVersionStr/tlinux32upd$AppVersion tmaster:tdesktop/www/tlinux32/
scp ./../Linux/Release/deploy/$AppVersionStr/tsetup32.$AppVersionStr.tar.xz tmaster:tdesktop/www/tlinux32/

View file

@ -104,7 +104,10 @@ Application::Application(int &argc, char **argv) : PsApplication(argc, argv),
installEventFilter(new _DebugWaiter(this));
#if defined Q_OS_LINUX || defined Q_OS_LINUX64
QFontDatabase::addApplicationFont(qsl(":/gui/art/fonts/DejaVuSans.ttf"));
QFontDatabase::addApplicationFont(qsl(":/gui/art/fonts/NanumMyeongjo-Regular.ttf"));
#endif
QFontDatabase::addApplicationFont(qsl(":/gui/art/fonts/OpenSans-Regular.ttf"));
QFontDatabase::addApplicationFont(qsl(":/gui/art/fonts/OpenSans-Bold.ttf"));
QFontDatabase::addApplicationFont(qsl(":/gui/art/fonts/OpenSans-Semibold.ttf"));

View file

@ -2770,12 +2770,14 @@ void HistoryWidget::updateOnlineDisplay(int32 x, int32 w) {
text = titlePeerText.isEmpty() ? lang(lng_chat_members).arg(chat->count) : titlePeerText;
} else {
int32 onlineCount = 0;
bool onlyMe = true;
for (ChatData::Participants::const_iterator i = chat->participants.cbegin(), e = chat->participants.cend(); i != e; ++i) {
if (i.key()->onlineTill > t) {
++onlineCount;
if (onlyMe && i.key() != App::self()) onlyMe = false;
}
}
if (onlineCount) {
if (onlineCount && !onlyMe) {
text = lang(lng_chat_members_online).arg(chat->participants.size()).arg(onlineCount);
} else {
text = lang(lng_chat_members).arg(chat->participants.size());

View file

@ -280,7 +280,7 @@ void TopBarWidget::showAll() {
_mediaType.hide();
}
}
if (App::main() && App::main()->historyPeer() && !cWideMode()) {
if (App::main() && App::main()->historyPeer() && !p && _clearSelection.isHidden() && !cWideMode()) {
_info.show();
} else {
_info.hide();

View file

@ -748,9 +748,9 @@ void MediaView::keyPressEvent(QKeyEvent *e) {
moveToPhoto(-1);
} else if (e->key() == Qt::Key_Right) {
moveToPhoto(1);
} else if (e->modifiers().testFlag(Qt::ControlModifier) && (e->key() == Qt::Key_Plus || e->key() == Qt::Key_Equal || e->key() == Qt::Key_Minus || e->key() == Qt::Key_Underscore || e->key() == Qt::Key_0)) {
} else if (e->modifiers().testFlag(Qt::ControlModifier) && (e->key() == Qt::Key_Plus || e->key() == Qt::Key_Equal || e->key() == ']' || e->key() == Qt::Key_Asterisk || e->key() == Qt::Key_Minus || e->key() == Qt::Key_Underscore || e->key() == Qt::Key_0)) {
int32 newZoom = _zoom;
if (e->key() == Qt::Key_Plus || e->key() == Qt::Key_Equal) {
if (e->key() == Qt::Key_Plus || e->key() == Qt::Key_Equal || e->key() == Qt::Key_Asterisk || e->key() == ']') {
if (newZoom == ZoomToScreenLevel) {
if (qCeil(_zoomToScreen) <= MaxZoomLevel) {
newZoom = qCeil(_zoomToScreen);

View file

@ -338,7 +338,8 @@ void ProfileInner::reorderParticipants() {
_participantsData.resize(_peerChat->participants.size());
}
UserData *self = App::self();
for (ChatData::Participants::const_iterator i = _peerChat->participants.cbegin(), e = _peerChat->participants.cend(); i != e; ++i) {
bool onlyMe = true;
for (ChatData::Participants::const_iterator i = _peerChat->participants.cbegin(), e = _peerChat->participants.cend(); i != e; ++i) {
UserData *user = i.key();
int32 until = App::onlineForSort(user->onlineTill, t);
Participants::iterator before = _participants.begin();
@ -349,7 +350,8 @@ void ProfileInner::reorderParticipants() {
while (before != _participants.end() && App::onlineForSort((*before)->onlineTill, t) >= until) {
++before;
}
}
if (until > t && onlyMe) onlyMe = false;
}
_participants.insert(before, user);
if (until > t) {
++onlineCount;
@ -358,7 +360,7 @@ void ProfileInner::reorderParticipants() {
if (_peerChat->count > 0 && _participants.isEmpty() && !_loadingId) {
_loadingId = MTP::send(MTPmessages_GetFullChat(App::peerToMTP(_peerChat->id).c_peerChat().vchat_id), rpcDone(&ProfileInner::gotFullChat));
if (_onlineText.isEmpty()) _onlineText = lang(lng_chat_members).arg(_peerChat->count);
} else if (onlineCount) {
} else if (onlineCount && !onlyMe) {
_onlineText = lang(lng_chat_members_online).arg(_participants.size()).arg(onlineCount);
} else {
_onlineText = lang(lng_chat_members).arg(_participants.size());

View file

@ -19,8 +19,7 @@
<file>art/blank.gif</file>
<file>art/icon256.png</file>
<file>art/iconbig256.png</file>
<file>art/fonts/DejaVuSans.ttf</file>
<file>art/osxtray.png</file>
<file>art/osxtray.png</file>
</qresource>
<qresource prefix="/ava">
<file>art/chatcolor1.png</file>

View file

@ -19,6 +19,7 @@
<file>art/blank.gif</file>
<file>art/icon256.png</file>
<file>art/fonts/DejaVuSans.ttf</file>
<file>art/fonts/NanumMyeongjo-Regular.ttf</file>
</qresource>
<qresource prefix="/ava">
<file>art/chatcolor1.png</file>