mirror of
https://github.com/kotatogram/kotatogram-desktop
synced 2025-08-30 22:25:12 +00:00
Add some icons to popup menus.
This commit is contained in:
@@ -37,6 +37,7 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
|
||||
#include "lang/lang_keys.h"
|
||||
#include "styles/style_info.h"
|
||||
#include "styles/style_profile.h"
|
||||
#include "styles/style_menu_icons.h"
|
||||
|
||||
namespace Info {
|
||||
namespace {
|
||||
@@ -529,7 +530,9 @@ void WrapWidget::showTopBarMenu() {
|
||||
Ui::InnerDropdown::HideOption::IgnoreShow);
|
||||
return;
|
||||
}
|
||||
_topBarMenu = base::make_unique_q<Ui::DropdownMenu>(this);
|
||||
_topBarMenu = base::make_unique_q<Ui::DropdownMenu>(
|
||||
this,
|
||||
st::dropdownMenuWithIcons);
|
||||
|
||||
_topBarMenu->setHiddenCallback([this] {
|
||||
InvokeQueued(this, [this] { _topBarMenu = nullptr; });
|
||||
@@ -551,8 +554,9 @@ void WrapWidget::showTopBarMenu() {
|
||||
|
||||
const auto addAction = [=](
|
||||
const QString &text,
|
||||
Fn<void()> callback) {
|
||||
return _topBarMenu->addAction(text, std::move(callback));
|
||||
Fn<void()> callback,
|
||||
const style::icon *icon) {
|
||||
return _topBarMenu->addAction(text, std::move(callback), icon);
|
||||
};
|
||||
if (const auto peer = key().peer()) {
|
||||
Window::FillDialogsEntryMenu(
|
||||
|
Reference in New Issue
Block a user