From: suhyung Eom Date: Mon, 21 Nov 2016 04:06:22 +0000 (+0900) Subject: [3.0] Implemented Window::SetClass() functionality in window-impl-ecore-wl.cpp X-Git-Tag: accepted/tizen/3.0/common/20161124.181854~4 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=b939c8714d83efaab975f982164478aeb3b1eead;hp=ac0060762bc6e231c475229d7ffd7a6096f9c46d;p=platform%2Fcore%2Fuifw%2Fdali-adaptor.git [3.0] Implemented Window::SetClass() functionality in window-impl-ecore-wl.cpp Signed-off-by: suhyung Eom Change-Id: I6642bafffea6020b5a9aedd91190dfd6438497d4 --- diff --git a/adaptors/ecore/wayland/window-impl-ecore-wl.cpp b/adaptors/ecore/wayland/window-impl-ecore-wl.cpp index 5849317..184299c 100644 --- a/adaptors/ecore/wayland/window-impl-ecore-wl.cpp +++ b/adaptors/ecore/wayland/window-impl-ecore-wl.cpp @@ -244,6 +244,18 @@ void Window::SetIndicatorBgOpacity( Dali::Window::IndicatorBgOpacity opacityMode void Window::SetClass(std::string name, std::string klass) { + ECore::WindowRenderSurface* wlSurface( dynamic_cast< ECore::WindowRenderSurface * >( mSurface ) ); + + if( wlSurface ) + { + Ecore_Wl_Window* wlWindow = wlSurface->GetWlWindow(); + ecore_wl_window_title_set( wlWindow, name.c_str() ); + ecore_wl_window_class_name_set( wlWindow, klass.c_str() ); + } + else + { + DALI_LOG_INFO( gWindowLogFilter, Debug::General, "Window has no surface\n" ); + } } Window::Window() @@ -291,15 +303,10 @@ void Window::Initialize(const PositionSize& windowPosition, const std::string& n // create an Wayland window by default Any surface; ECore::WindowRenderSurface* windowSurface = new ECore::WindowRenderSurface( windowPosition, surface, name, mIsTransparent ); - SetClass( name, className ); - windowSurface->Map(); mSurface = windowSurface; - - std::string appId; - mAdaptor->GetAppId( appId ); - Ecore_Wl_Window* wlWindow = windowSurface ->GetWlWindow(); - ecore_wl_window_class_name_set(wlWindow, appId.c_str()); + SetClass( name, className ); + windowSurface->Map(); mOrientation = Orientation::New(this);