Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
b4698 -- Уточнение 4697 - не пытаемся отключать Win10 full-screen
  • Loading branch information
w17 committed Jun 8, 2016
1 parent d3a54ca commit 64f1ca2
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 11 deletions.
4 changes: 4 additions & 0 deletions far/changelog
@@ -1,3 +1,7 @@
w17 08.06.2016 21:15:44 +0300 - build 4698

1. Уточнение 4697 - не пытаемся отключать Win10 full-screen, просто ничего не делаем по Alt-F9 для него.

w17 08.06.2016 17:25:01 +0300 - build 4697

1. Пытаемся нормально отрабатывать полноэкранный режим Win10.
Expand Down
2 changes: 1 addition & 1 deletion far/console.cpp
Expand Up @@ -97,7 +97,7 @@ virtual bool GetSize(COORD& Size) const override

if (!Global->Opt->WindowMode)
{
auto style = ::GetWindowLong(GetWindow(), GWL_STYLE);
auto style = ::GetWindowLongPtr(GetWindow(), GWL_STYLE);
if (style & (WS_HSCROLL | WS_VSCROLL))
{
RECT cr;
Expand Down
13 changes: 4 additions & 9 deletions far/interf.cpp
Expand Up @@ -441,19 +441,14 @@ void SetVideoMode()
if (!IsConsoleFullscreen() && Global->Opt->AltF9) // hardware full-screen check
{
DWORD dmode = 0;
if (IsWindows10OrGreater() && Console().GetDisplayMode(dmode) && (dmode & CONSOLE_FULLSCREEN) != 0) // win10 graphic full-screen
{
#ifndef _WIN64
::SetConsoleDisplayMode(Console().GetOutputHandle(), CONSOLE_WINDOWED_MODE, nullptr); // turn off full-screen
#else
return; // don't know how to turn off full-screen mode on Win10 x64 -- so just do not change video mode
#endif
}
if (IsWindows10OrGreater() && Console().GetDisplayMode(dmode) && (dmode & CONSOLE_FULLSCREEN) != 0)
return; // ignore Alt-F9 in Win10 full-screen mode

ChangeVideoMode(InitSize.X==CurSize.X && InitSize.Y==CurSize.Y);
}
else
{
ChangeVideoMode(ScrY==24?50:25,80);
ChangeVideoMode(ScrY == 24 ? 50 : 25, 80);
}
}

Expand Down
2 changes: 1 addition & 1 deletion far/vbuild.m4
@@ -1 +1 @@
m4_define(BUILD,4697)m4_dnl
m4_define(BUILD,4698)m4_dnl

0 comments on commit 64f1ca2

Please sign in to comment.