From a66459f999755facca0ad07198bd768b9959d164 Mon Sep 17 00:00:00 2001 From: jooyoul_lee Date: Fri, 16 May 2014 12:22:44 +0900 Subject: [PATCH] NSCREEN : initial style apply bug fixed start time css style applied Change-Id: I1f962ec205918d5070a4bd8e665c3945fc457c5b Signed-off-by: jooyoul_lee --- .../org/tizen/webuibuilder/ui/editor/PageDesigner.java | 17 +++-------------- .../webuibuilder/ui/editor/PageDesignerToolbar.java | 2 ++ 2 files changed, 5 insertions(+), 14 deletions(-) diff --git a/org.tizen.webuibuilder/src/org/tizen/webuibuilder/ui/editor/PageDesigner.java b/org.tizen.webuibuilder/src/org/tizen/webuibuilder/ui/editor/PageDesigner.java index e5eaa1a..16c53c1 100644 --- a/org.tizen.webuibuilder/src/org/tizen/webuibuilder/ui/editor/PageDesigner.java +++ b/org.tizen.webuibuilder/src/org/tizen/webuibuilder/ui/editor/PageDesigner.java @@ -381,7 +381,9 @@ public class PageDesigner extends GraphicalEditor implements CommandStackListene NScreenUtil.nscreen_log("current page css : " + pageData.getCurrentCssFile().getCssFilePath()); - getViewer().updateStyle(); + if (getViewer() != null) { + getViewer().updateStyle(); + } } @@ -407,19 +409,6 @@ public class PageDesigner extends GraphicalEditor implements CommandStackListene protected void clearSelectorsOfRootPart() { rootPart.clearAllSelector(); - // CssFile currentCssFile = pageData.getCurrentCssFile(); - // Collection selectors = rootPart.getSelectors(); - // for (CssSelector selector : currentCssFile.getSelectors()) { - // String pageId = selector.getPageId(); - // Part pagePart = rootPart.getChildOfIdPropertyValue(pageId, true); - // if (pagePart != null) { - // String partId = selector.getPartId(); - // Part part = rootPart.getChildOfIdPropertyValue(partId, true); - // if (part != null) { - // part.removeSelector(selector.getSelectorName(), false); - // } - // } - // } } private DescriptorManager getDescriptorManager() { diff --git a/org.tizen.webuibuilder/src/org/tizen/webuibuilder/ui/editor/PageDesignerToolbar.java b/org.tizen.webuibuilder/src/org/tizen/webuibuilder/ui/editor/PageDesignerToolbar.java index 085bb84..67d77f7 100644 --- a/org.tizen.webuibuilder/src/org/tizen/webuibuilder/ui/editor/PageDesignerToolbar.java +++ b/org.tizen.webuibuilder/src/org/tizen/webuibuilder/ui/editor/PageDesignerToolbar.java @@ -203,10 +203,12 @@ public class PageDesignerToolbar implements ISelectionListener { } nscreen = new NScreenHistory(); nscreen.setLastResolution(device.getDisplayName()); + nscreen.setModelName(BuilderConstants.NSCREENCOMMON); nscreen.setScale(1f); currentScreen = resolution.getScreenSize(device.getDisplayName()); screenSizeText.setText(currentScreen.getScreenSize()); + mainEditor.setNscreenIndex2(device, nscreen); } public void setResolution(List devices, NScreenItem nsItem) { -- 2.7.4