Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(227)

Unified Diff: ash/wm/default_state.cc

Issue 247363005: Fullscreen/immersive mode is allowed in touch view mode, the shelf gets hidden and an edge swipe br… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ash/wm/default_state.cc
diff --git a/ash/wm/default_state.cc b/ash/wm/default_state.cc
index de4c60caf45ef59f4e14a8a9209eda3751d62f5d..a26e78c166a72c3c17d541b21503caadec97e8cb 100644
--- a/ash/wm/default_state.cc
+++ b/ash/wm/default_state.cc
@@ -12,6 +12,7 @@
#include "ash/wm/window_animations.h"
#include "ash/wm/window_state.h"
#include "ash/wm/window_state_delegate.h"
+#include "ash/wm/window_state_util.h"
#include "ash/wm/window_util.h"
#include "ash/wm/wm_event.h"
#include "ash/wm/workspace/workspace_window_resizer.h"
@@ -258,25 +259,9 @@ bool DefaultState::ProcessCompoundEvents(WindowState* window_state,
}
return true;
}
- case WM_EVENT_TOGGLE_FULLSCREEN: {
- // Window which cannot be maximized should not be fullscreened.
- // It can, however, be restored if it was fullscreened.
- bool is_fullscreen = window_state->IsFullscreen();
- if (!is_fullscreen && !window_state->CanMaximize())
- return true;
- if (window_state->delegate() &&
- window_state->delegate()->ToggleFullscreen(window_state)) {
- return true;
- }
- if (is_fullscreen) {
- window_state->Restore();
- } else {
- //
- window_state->window()->SetProperty(aura::client::kShowStateKey,
- ui::SHOW_STATE_FULLSCREEN);
- }
+ case WM_EVENT_TOGGLE_FULLSCREEN:
+ ToggleFullScreen(window_state, window_state->delegate());
return true;
- }
case WM_EVENT_CENTER:
CenterWindow(window_state);
return true;
« no previous file with comments | « ash/shelf/shelf_layout_manager_unittest.cc ('k') | ash/wm/maximize_mode/maximize_mode_window_manager_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698