# Tizen Profile options
AC_ARG_ENABLE([profile],
- [AC_HELP_STRING([--enable-profile=COMMON,MOBILE,WEARABLE,TV],
+ [AC_HELP_STRING([--enable-profile=UBUNTU,MOBILE,WEARABLE,TV],
[Select the variant of tizen])],
[dali_profile=$enableval],
- [dali_profile=COMMON])
+ [dali_profile=UBUNTU])
+
+# Ensure valid profile selected
+if test "x$dali_profile" != "xUBUNTU" -a "x$dali_profile" != "xMOBILE" -a "x$dali_profile" != "xWEARABLE" -a "x$dali_profile" != "xTV" ; then
+ AC_MSG_ERROR([$enable_profile is an invalid profile])
+fi
if test x$DALI_DATA_RW_DIR != x; then
dataReadWriteDir=${DALI_DATA_RW_DIR}/
dataReadOnlyDir=${prefix}/share/dali/
fi
-DALI_TOOLKIT_CFLAGS="$DALI_TOOLKIT_CFLAGS -DDALI_PROFILE_${enable_profile}"
-AM_CONDITIONAL([COMMON_PROFILE], [test x$enable_profile = xCOMMON])
-AM_CONDITIONAL([MOBILE_PROFILE], [test x$enable_profile = xMOBILE])
+DALI_TOOLKIT_CFLAGS="$DALI_TOOLKIT_CFLAGS -DDALI_PROFILE_${dali_profile}"
+
+# Style paths
+if test "x$dali_profile" = "xUBUNTU"; then
+ STYLE_DIR=../../../dali-toolkit/styles
+fi
+
+if test "x$dali_profile" = "xMOBILE"; then
+ STYLE_DIR=../../../dali-toolkit/styles/mobile
+fi
+
+AC_SUBST(STYLE_DIR)
# v8 version 4+ requires c++11
PKG_CHECK_MODULES(V8, v8 = 3.32.7, [ pkg_check_v8=yes ], [ pkg_check_v8=no ] )
public_api_src_dir = ../../../dali-toolkit/public-api
devel_api_src_dir = ../../../dali-toolkit/devel-api
-if MOBILE_PROFILE
-toolkit_styles_dir = ../../../dali-toolkit/styles/mobile
-else
-toolkit_styles_dir = ../../../dali-toolkit/styles
-endif
+toolkit_styles_dir = $(STYLE_DIR)
include ../../../dali-toolkit/images/file.list
include ../../../dali-toolkit/sounds/file.list
// todo Move this to adaptor??
#define GET_LOCALE_TEXT(string) dgettext("elementary", string)
+const std::string TEXT_SELECTION_POPUP_LABEL = "textselectionpopuplabel";
+
const Dali::Vector4 DEFAULT_POPUP_DIVIDER_COLOR( Dali::Vector4( 0.23f, 0.72f, 0.8f, 0.11f ) );
const Dali::Vector4 DEFAULT_OPTION_ICON( Dali::Vector4( 1.0f, 1.0f, 1.0f, 1.0f ) );
const Dali::Vector4 DEFAULT_OPTION_PRESSED_COLOR( Dali::Vector4( 0.24f, 0.72f, 0.8f, 0.11f ) );
+const float DEFAULT_CAPTION_POINT_SIZE = 8.0f; // todo This should be from the style sheet not fixed.
+
const std::string DEFAULT_POPUP_BACKGROUND_IMAGE( DALI_IMAGE_DIR "selection-popup-bg#.png" );
const std::string OPTION_ICON_CLIPBOARD( DALI_IMAGE_DIR "copy_paste_icon_clipboard.png" );
const std::string OPTION_ICON_COPY( DALI_IMAGE_DIR "copy_paste_icon_copy.png" );
Dali::Toolkit::TextSelectionPopup handle( *impl );
impl->mEnabledButtons = buttonsToEnable;
-
// Second-phase init of the implementation
// This can only be done after the CustomActor connection has been made...
impl->Initialize();
if ( showCaption )
{
Toolkit::TextLabel captionTextLabel = Toolkit::TextLabel::New();
+ captionTextLabel.SetStyleName( TEXT_SELECTION_POPUP_LABEL );
captionTextLabel.SetProperty( Toolkit::TextLabel::Property::TEXT, caption );
+ captionTextLabel.SetProperty( Toolkit::TextLabel::Property::POINT_SIZE, DEFAULT_CAPTION_POINT_SIZE );
captionTextLabel.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::ALL_DIMENSIONS );
Toolkit::TextLabel pressedCaptionTextLabel = Toolkit::TextLabel::New();
+ pressedCaptionTextLabel.SetStyleName( TEXT_SELECTION_POPUP_LABEL );
pressedCaptionTextLabel.SetProperty( Toolkit::TextLabel::Property::TEXT, caption );
+ pressedCaptionTextLabel.SetProperty( Toolkit::TextLabel::Property::POINT_SIZE, DEFAULT_CAPTION_POINT_SIZE );
pressedCaptionTextLabel.SetResizePolicy( ResizePolicy::USE_NATURAL_SIZE, Dimension::ALL_DIMENSIONS );
Padding padding;
"font-style":"Regular",
"point-size":18
},
+ "textselectionpopuplabel":
+ {
+ "point-size":18
+ },
"textselectionpopup":
{
"popup-max-size":[400,100],
- "popup-min-size":[100,65],
- "background-color":[0.0,0.0,0.0,1.0]
+ "popup-min-size":[100,65]
},
"textfield":
{
{
"point-size":10
},
+ "textselectionpopuplabel":
+ {
+ "point-size":8
+ },
"textselectionpopup":
{
"popup-max-size":[400,100],
- "popup-min-size":[100,65],
- "background-color":[0.0,0.0,0.0,1.0]
+ "popup-min-size":[100,65]
},
"scrollview":
{
BuildRequires: pkgconfig(dali)
BuildRequires: pkgconfig(dali-core)
+#############################
+# profile setup
+#############################
+
+%define dali_toolkit_profile MOBILE
+
+# Further resource locations profiles can be provided here otherwise MOBILE will be used
+%if "%{tizen_profile_name}" == "mobile"
+ %define dali_toolkit_profile MOBILE
+%endif
+
%description
The OpenGLES Canvas Core Library Toolkit - a set of controls that provide
user interface functionality.
autoreconf --install
DALI_DATA_RW_DIR="%{dali_data_rw_dir}" ; export DALI_DATA_RW_DIR
DALI_DATA_RO_DIR="%{dali_data_ro_dir}" ; export DALI_DATA_RO_DIR
-%configure
+%configure --enable-profile=%{dali_toolkit_profile}
make %{?jobs:-j%jobs}
##############################