Always shows window frame except for maximized window on Unity.
This commit is contained in:
parent
14235a65a9
commit
0f5b427648
1 changed files with 12 additions and 1 deletions
|
@ -6,6 +6,10 @@
|
||||||
|
|
||||||
#include "ui/views/widget/desktop_aura/desktop_native_widget_aura.h"
|
#include "ui/views/widget/desktop_aura/desktop_native_widget_aura.h"
|
||||||
|
|
||||||
|
#if defined(OS_LINUX)
|
||||||
|
#include "ui/views/linux_ui/linux_ui.h"
|
||||||
|
#endif
|
||||||
|
|
||||||
namespace brightray {
|
namespace brightray {
|
||||||
|
|
||||||
ViewsDelegate::ViewsDelegate() {
|
ViewsDelegate::ViewsDelegate() {
|
||||||
|
@ -95,7 +99,14 @@ base::TimeDelta ViewsDelegate::GetDefaultTextfieldObscuredRevealDuration() {
|
||||||
}
|
}
|
||||||
|
|
||||||
bool ViewsDelegate::WindowManagerProvidesTitleBar(bool maximized) {
|
bool ViewsDelegate::WindowManagerProvidesTitleBar(bool maximized) {
|
||||||
return maximized;
|
#if defined(OS_LINUX)
|
||||||
|
// On Ubuntu Unity, the system always provides a title bar for maximized
|
||||||
|
// windows.
|
||||||
|
views::LinuxUI* ui = views::LinuxUI::instance();
|
||||||
|
return maximized && ui && ui->UnityIsRunning();
|
||||||
|
#else
|
||||||
|
return false;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
} // namespace brightray
|
} // namespace brightray
|
||||||
|
|
Loading…
Reference in a new issue