From ced80d7acab9c72690a4b497870c8b6bcd806f23 Mon Sep 17 00:00:00 2001 From: Robert Erickson Date: Tue, 18 Nov 2014 18:59:12 -0200 Subject: [PATCH] Add default_1080 theme Change-Id: If2452283b24b5ef8c02147630e40357a04420ebc Signed-off-by: Eduardo Lima (Etrunko) --- data/themes/Makefile.am | 12 +++++++++++- data/themes/default/default_1080.edc | 26 ++++++++++++++++++++++++++ src/wkb-main.c | 4 +++- 3 files changed, 40 insertions(+), 2 deletions(-) create mode 100644 data/themes/default/default_1080.edc diff --git a/data/themes/Makefile.am b/data/themes/Makefile.am index fd143f5..3b2a9ec 100644 --- a/data/themes/Makefile.am +++ b/data/themes/Makefile.am @@ -8,11 +8,13 @@ EDJE_FLAGS = $(EDJE_FLAGS_VERBOSE_$(V)) filesdir = $(pkgdatadir) files_DATA = default_600.edj \ - default_720.edj + default_720.edj \ + default_1080.edj DEFAULT_FILES = default/default.edc \ default/default_600.edc \ default/default_720.edc \ + default/default_1080.edc \ default/ignorekeys.txt \ default/fonts/DroidSans-Bold.ttf \ default/fonts/DroidSans.ttf \ @@ -47,5 +49,13 @@ default_720.edj: Makefile default/default_720.edc $(default_FILES) $(top_srcdir)/data/themes/default/default_720.edc \ $(top_builddir)/data/themes/default_720.edj +default_1080.edj: Makefile default/default_1080.edc $(default_FILES) + $(EDJE_CC) $(EDJE_FLAGS) \ + -dd $(top_srcdir)/data/themes/default \ + -id $(top_srcdir)/data/themes/default/images \ + -fd $(top_srcdir)/data/themes/default/fonts \ + $(top_srcdir)/data/themes/default/default_1080.edc \ + $(top_builddir)/data/themes/default_1080.edj + clean-local: rm -f $(top_builddir)/data/themes/*.edj diff --git a/data/themes/default/default_1080.edc b/data/themes/default/default_1080.edc new file mode 100644 index 0000000..d5f23d6 --- /dev/null +++ b/data/themes/default/default_1080.edc @@ -0,0 +1,26 @@ +/* + * Copyright © 2014 Jaguar Landrover + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +#define SCALE 1.5 + +#define MIN_WIDTH 1080 +#define MAX_WIDTH 1280 +#define MIN_HEIGHT 900 +#define MAX_HEIGHT 900 + +#define NUMERIC_KEY_HEIGHT 150 + +#include "default.edc" diff --git a/src/wkb-main.c b/src/wkb-main.c index 5c38e4f..86464db 100644 --- a/src/wkb-main.c +++ b/src/wkb-main.c @@ -423,7 +423,9 @@ _wkb_ui_setup(struct weekeyboard *wkb) /* Check which theme we should use according to the screen width */ ecore_wl_screen_size_get(&w, &h); DBG("Screen size: w=%d, h=%d", w, h); - if (w >= 720) + if (w >= 1080) + w = 1080; + else if (w >= 720) w = 720; else w = 600; -- 2.34.1