summaryrefslogtreecommitdiff
path: root/org.tizen.common.ui
diff options
context:
space:
mode:
authorkh5325.kim <kh5325.kim@samsung.com>2014-02-07 19:15:28 +0900
committerkh5325.kim <kh5325.kim@samsung.com>2014-02-07 19:15:28 +0900
commitcf3db4d9385c0105a53c78225a92535e8b22d1ee (patch)
tree470a3c8d4d07ca9ab729bf506f1949fe0d312b43 /org.tizen.common.ui
parent040f822a176a2087c4e3a42778be7a5696ac25f2 (diff)
downloadcommon-eplugin-cf3db4d9385c0105a53c78225a92535e8b22d1ee.tar.gz
common-eplugin-cf3db4d9385c0105a53c78225a92535e8b22d1ee.tar.bz2
common-eplugin-cf3db4d9385c0105a53c78225a92535e8b22d1ee.zip
COMMON: COMMAND BAR: Extracted perspective name to bundle
Extracted perspective name to bundle. Change-Id: I9e19da1ce984dd7c17c10f568361afaed01e53ff Signed-off-by: kh5325.kim <kh5325.kim@samsung.com>
Diffstat (limited to 'org.tizen.common.ui')
-rw-r--r--org.tizen.common.ui/src/org/tizen/common/ui/commandbar/Messages.java46
-rw-r--r--org.tizen.common.ui/src/org/tizen/common/ui/commandbar/OrderCommandCallback.java7
-rw-r--r--org.tizen.common.ui/src/org/tizen/common/ui/commandbar/messages.properties2
3 files changed, 51 insertions, 4 deletions
diff --git a/org.tizen.common.ui/src/org/tizen/common/ui/commandbar/Messages.java b/org.tizen.common.ui/src/org/tizen/common/ui/commandbar/Messages.java
new file mode 100644
index 000000000..41efb85d4
--- /dev/null
+++ b/org.tizen.common.ui/src/org/tizen/common/ui/commandbar/Messages.java
@@ -0,0 +1,46 @@
+/*
+* NativeAppCommon
+*
+* Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
+*
+* Contact:
+* Kangho Kim <kh5325.kim@samsung.com>
+* NamKoong Ho <ho.namkoong@samsung.com>
+*
+* 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.
+*
+* Contributors:
+* - S-Core Co., Ltd
+*
+*/
+package org.tizen.common.ui.commandbar;
+
+import org.eclipse.osgi.util.NLS;
+import org.tizen.common.ui.Activator;
+
+
+public class Messages extends NLS {
+
+ private static final String BUNDLE_NAME = Activator.PLUGIN_ID + ".commandbar.messages";//$NON-NLS-1$
+
+ private Messages() {
+ // Do not instantiate
+ }
+
+ public static String Perspective_Native;
+ public static String Perspective_Web;
+
+ static {
+ NLS.initializeMessages(BUNDLE_NAME, Messages.class);
+ }
+}
diff --git a/org.tizen.common.ui/src/org/tizen/common/ui/commandbar/OrderCommandCallback.java b/org.tizen.common.ui/src/org/tizen/common/ui/commandbar/OrderCommandCallback.java
index 5009da362..2ecae2e95 100644
--- a/org.tizen.common.ui/src/org/tizen/common/ui/commandbar/OrderCommandCallback.java
+++ b/org.tizen.common.ui/src/org/tizen/common/ui/commandbar/OrderCommandCallback.java
@@ -67,8 +67,7 @@ public class OrderCommandCallback implements CommandCallback {
CommandException cause = (CommandException) order.getError().getCause();
switch (cause.getType()) {
case CommandException.PROJECT_NOPERSPECTIVE :
- String assist = String.format("This perspective does not support project creation.%n" +
- "Please switch to the <a>Tizen Web</a> or <a>Tizen Native</a>.");
+ String assist = String.format("This perspective does not support project creation.");
Listener asListener = new PerspectiveChangeListener();
setReceipt(new Receipt(order.getText(), assist, asListener));
break;
@@ -85,11 +84,11 @@ public class OrderCommandCallback implements CommandCallback {
String sProject = null, sPerspective = null;
if (webId.equals(activePerspectiveId)) {
sProject = "native";
- sPerspective = "Tizen Native";
+ sPerspective = Messages.Perspective_Native;
}
else if (nativeId.equals(activePerspectiveId)) {
sProject = "web";
- sPerspective = "Tizen Web";
+ sPerspective = Messages.Perspective_Web;
}
if (sProject != null) {
String assist = String.format("Did you know it?%n" +
diff --git a/org.tizen.common.ui/src/org/tizen/common/ui/commandbar/messages.properties b/org.tizen.common.ui/src/org/tizen/common/ui/commandbar/messages.properties
new file mode 100644
index 000000000..ba169e0ac
--- /dev/null
+++ b/org.tizen.common.ui/src/org/tizen/common/ui/commandbar/messages.properties
@@ -0,0 +1,2 @@
+Perspective_Native = Tizen Native
+Perspective_Web = Tizen Web