/* create and add devices. */
mDevice = pepper_input_device_create( static_cast< pepper_compositor_t* >( Pepper::GetImplementation( compositor ).GetCompositorHandle() ),
- WL_SEAT_CAPABILITY_TOUCH, NULL, NULL );
+ WL_SEAT_CAPABILITY_KEYBOARD | WL_SEAT_CAPABILITY_TOUCH, NULL, NULL );
// mDevice = pepper_input_device_create( static_cast< pepper_compositor_t* >( Pepper::GetImplementation( compositor ).GetCompositorHandle() ),
// ( WL_SEAT_CAPABILITY_POINTER | WL_SEAT_CAPABILITY_KEYBOARD | WL_SEAT_CAPABILITY_TOUCH ), NULL, NULL );
if( !mDevice )
void Output::OnRepaint( void* data, const pepper_list_t* planeList )
{
+ Output* output = static_cast< Output* >( data );
+
DALI_LOG_INFO( gPepperOutputLogging, Debug::Verbose, "Output::OnRepaint\n" );
// TODO: repaint
+ if( !output->mRenderFinishTimer )
+ {
+ output->mRenderFinishTimer= Timer::New(10);
+ output->mRenderFinishTimer.TickSignal().Connect( output, &Output::OnRenderFinishTimerTick );
+ }
+
+ output->mRenderFinishTimer.Start();
}
void Output::OnAttachSurface( void* data, pepper_surface_t* surface, int* width, int* height )
if( *iter == object )
{
mObjectList.erase( iter );
+ break;
}
}
}
+// TODO: temp
+bool Output::OnRenderFinishTimerTick()
+{
+ struct timespec ts;
+
+ DALI_LOG_INFO( gPepperOutputLogging, Debug::Verbose, "Output::OnRenderFinishTimerTick\n" );
+
+ pepper_compositor_get_time( static_cast< pepper_compositor_t* >( Pepper::GetImplementation( mCompositor ).GetCompositorHandle() ), &ts );
+ pepper_output_finish_frame( mOutput, &ts );
+
+ return false;
+}
+
} // namespace Internal
} // namespace Pepper
#include <dali/public-api/signals/connection-tracker.h>
#include <pepper-output-backend.h>
+// TODO: temp
+#include <dali/public-api/adaptor-framework/timer.h>
+
namespace Dali
{
void OnObjectViewAdded( Pepper::Object object, Pepper::ObjectView objectView );
void OnObjectViewDeleted( Pepper::Object object, Pepper::ObjectView objectView );
+ // TODO: temp
+ bool OnRenderFinishTimerTick();
+
private:
// Undefined
// Signals
Pepper::Output::OutputSignalType mObjectViewAddedSignal;
Pepper::Output::OutputSignalType mObjectViewDeletedSignal;
+
+ // TODO: temp
+ Timer mRenderFinishTimer;
};
} // namespace Internal
DALI_LOG_INFO( gPepperShellClientLogging, Debug::Verbose, "ShellClient::GetSurface: success. surface = %p\n", mSurface );
}
-void ShellClient::SetTitle( const std::string title )
+void ShellClient::SetTitle( const std::string& title )
{
mTitle = title;
}
-std::string ShellClient::GetTitle() const
+const std::string& ShellClient::GetTitle() const
{
return mTitle;
}
-void ShellClient::SetAppId( const std::string appId )
+void ShellClient::SetAppId( const std::string& appId )
{
mAppId = appId;
}
-std::string ShellClient::GetAppId() const
+const std::string& ShellClient::GetAppId() const
{
return mAppId;
}
shellClient->mAppId.clear();
}
- if( !shellClient->mSurface )
+ if( shellClient->mSurface )
{
pepper_object_set_user_data( reinterpret_cast< pepper_object_t* >( shellClient->mSurface ), pepper_surface_get_role( shellClient->mSurface ), NULL, NULL );
}
pepper_view_t* GetView();
void GetSurface( wl_client* client, unsigned int id, wl_resource* surfaceResource );
- void SetTitle( const std::string title );
- std::string GetTitle() const;
+ void SetTitle( const std::string& title );
+ const std::string& GetTitle() const;
- void SetAppId( const std::string appId );
- std::string GetAppId() const;
+ void SetAppId( const std::string& appId );
+ const std::string& GetAppId() const;
private:
if( *iter == shellClient )
{
mShellClientList.erase( iter );
+ break;
}
}