aboutsummaryrefslogtreecommitdiffstats
path: root/src/window_manager.cpp
diff options
context:
space:
mode:
authorYuta Doi <yuta-d@witz-inc.co.jp>2018-06-29 09:31:46 +0900
committerYuta Doi <yuta-d@witz-inc.co.jp>2018-07-09 10:04:53 +0900
commitdd72b1c91895058d14bd13c3aa9a50bd75f633b6 (patch)
treecc15ad1a3c7078bdb8f6cec08ff1b5b5c4e497d7 /src/window_manager.cpp
parentcf05c2b5c92b9a79635aa2277a9d55449e14fab6 (diff)
Add configuration file for each area sizes
Add areas.db which has each area sizes. less-than-0 values refer to (MAX + 1 - $VALUE) and MAX is either screen width or height. layers.json had each area sizes until now, so removed the sizes from it. Change-Id: I5cf283581daaca41e2b9e3ee6e947478bff1189c Signed-off-by: Yuta Doi <yuta-d@witz-inc.co.jp>
Diffstat (limited to 'src/window_manager.cpp')
-rw-r--r--src/window_manager.cpp12
1 files changed, 1 insertions, 11 deletions
diff --git a/src/window_manager.cpp b/src/window_manager.cpp
index 481a5fb..de322df 100644
--- a/src/window_manager.cpp
+++ b/src/window_manager.cpp
@@ -687,6 +687,7 @@ int WindowManager::init_layers()
this->layout_commit();
+ this->layers.loadAreaDb();
this->layers.setupArea(o->width, o->height);
return 0;
@@ -721,17 +722,6 @@ void WindowManager::surface_set_layout(int surface_id, const std::string& area)
int w = rect.w;
int h = rect.h;
- // less-than-0 values refer to MAX + 1 - $VALUE
- // e.g. MAX is either screen width or height
- if (w < 0)
- {
- w = this->controller->output_size.w + 1 + w;
- }
- if (h < 0)
- {
- h = this->controller->output_size.h + 1 + h;
- }
-
HMI_DEBUG("wm", "surface_set_layout for surface %u on layer %u", surface_id,
layer_id);