}
else
{
- mGl.BufferData(GetTarget(), size, &memory[0], GL_STATIC_DRAW); //@todo Query - do we need other usages?
+ mGl.BufferData(GetTarget(), GLsizeiptr(size), &memory[0], GL_STATIC_DRAW); //@todo Query - do we need other usages?
mCreated = true;
}
}
mCallStack.PushCall("GetTextureTarget", "");
return GL_TEXTURE_EXTERNAL_OES;
};
- inline virtual const char* GetCustomFragmentPrefix() const
- {
- mCallStack.PushCall("GetCustomFragmentPrefix", "");
- return "#extension GL_OES_EGL_image_external:require\n";
- };
inline virtual bool ApplyNativeFragmentShader(std::string& shader)
{
mCallStack.PushCall("ApplyNativeFragmentShader", "");
}
END_TEST;
}
+
+int UtcDaliWindowAddInputRegion(void)
+{
+ Dali::Window instance;
+ try
+ {
+ Rect<int> includedInputRegion(0,0,720,640);
+ DevelWindow::IncludeInputRegion(instance, includedInputRegion);
+ DALI_TEST_CHECK(false); // Should not get here
+ }
+ catch(...)
+ {
+ DALI_TEST_CHECK(true); // We expect an assert
+ }
+ END_TEST;
+}
+
+int UtcDaliWindowSubtractInputRegion(void)
+{
+ Dali::Window instance;
+ try
+ {
+ Rect<int> includedInputRegion(0,0,720,1280);
+ DevelWindow::IncludeInputRegion(instance, includedInputRegion);
+
+ Rect<int> excludedInputRegion(0,641,720,640);
+ DevelWindow::ExcludeInputRegion(instance, excludedInputRegion);
+
+ DALI_TEST_CHECK(false); // Should not get here
+ }
+ catch(...)
+ {
+ DALI_TEST_CHECK(true); // We expect an assert
+ }
+ END_TEST;
+}
}
return -1;
}
+
+bool Dali::AtspiAccessibility::IsEnabled()
+{
+ return Dali::Accessibility::IsUp();
+}
DALI_ADAPTOR_API bool SuppressScreenReader(bool suppress);
/**
- * @brief Set ATSPI to be turned On or Off forcibly.
+ * @brief Sets ATSPI to be turned On or Off forcibly.
*
* @param[in] turnOn true to turn on, false to turn off.
* @return The status of ATSPI : 0(ATSPI OFF, ScreenReader OFF), 1(ATSPI ON, ScreenReader OFF),
DALI_ADAPTOR_API int SetForcefully(bool turnOn);
/**
- * @brief Get ATSPI status.
+ * @brief Gets ATSPI status.
* @return Status of ATSPI : 0(ATSPI OFF, ScreenReader OFF), 1(ATSPI ON, ScreenReader OFF),
* 2 (ATSPI OFF, ScreenReader ON), 3(ATSPI ON, ScreenReader ON)
*/
DALI_ADAPTOR_API int GetStatus();
+/**
+ * @brief Returns whether the state of Accessibility is enabled or not.
+ *
+ * @return True if Accessibility is enabled, false otherwise.
+ */
+DALI_ADAPTOR_API bool IsEnabled();
+
} //namespace AtspiAccessibility
} //namespace Dali
return mImpl->GetTextureTarget();
}
-const char* NativeImageSourceQueue::GetCustomFragmentPrefix() const
-{
- return mImpl->GetCustomFragmentPrefix();
-}
-
bool NativeImageSourceQueue::ApplyNativeFragmentShader(std::string& shader)
{
return mImpl->ApplyNativeFragmentShader(shader);
int GetTextureTarget() const override;
/**
- * @copydoc Dali::NativeImageInterface::GetCustomFragmentPrefix()
- */
- const char* GetCustomFragmentPrefix() const override;
-
- /**
* @copydoc Dali::NativeImageInterface::ApplyNativeFragmentShader()
*/
bool ApplyNativeFragmentShader(std::string& shader) override;
#include <vector>
// INTERNAL INCLUDES
+#include <dali/devel-api/adaptor-framework/web-engine-request-interceptor.h>
#include <dali/devel-api/adaptor-framework/web-engine-security-origin.h>
namespace Dali
{
public:
/**
+ * @brief WebView callback related with http request interceptor.
+ */
+ using WebEngineRequestInterceptedCallback = std::function<void(Dali::WebEngineRequestInterceptorPtr)>;
+
+ /**
* @brief Callback for getting web database origins.
*/
using WebEngineSecurityOriginAcquiredCallback = std::function<void(std::vector<std::unique_ptr<Dali::WebEngineSecurityOrigin>>&)>;
virtual void RegisterMimeOverriddenCallback(WebEngineMimeOverriddenCallback callback) = 0;
/**
+ * @brief Callback to be called when http request need be intercepted.
+ *
+ * @param[in] callback
+ */
+ virtual void RegisterRequestInterceptedCallback(WebEngineRequestInterceptedCallback callback) = 0;
+
+ /**
* @brief Toggle the cache to be enabled or disabled
* Function works asynchronously.
*
*
* @return the attribute data of the hit element in the coordinates of the hit test
*/
- virtual Dali::Property::Map& GetAttributes() const = 0;
+ virtual Dali::Property::Map GetAttributes() const = 0;
/**
* @brief Get the image file name extension of hit element of the hit test.
class WebEngineHttpAuthHandler;
class WebEngineLoadError;
class WebEnginePolicyDecision;
-class WebEngineRequestInterceptor;
class WebEngineSettings;
class HoverEvent;
class WheelEvent;
using VideoPlayingCallback = std::function<void(bool)>;
/**
- * @brief WebView callback related with http request interceptor.
- */
- using WebEngineRequestInterceptorCallback = std::function<void(std::unique_ptr<Dali::WebEngineRequestInterceptor>)>;
-
- /**
* @brief WebView callback related with console message logged.
*/
using WebEngineConsoleMessageReceivedCallback = std::function<void(std::unique_ptr<Dali::WebEngineConsoleMessage>)>;
virtual void RegisterFormRepostDecidedCallback(WebEngineFormRepostDecidedCallback callback) = 0;
/**
- * @brief Callback to be called when http request need be intercepted.
- *
- * @param[in] callback
- */
- virtual void RegisterRequestInterceptorCallback(WebEngineRequestInterceptorCallback callback) = 0;
-
- /**
* @brief Callback to be called when console message will be logged.
*
* @param[in] callback
*/
// EXTERNAL INCLUDES
+#include <dali/public-api/common/intrusive-ptr.h>
+#include <dali/public-api/object/property-map.h>
+#include <dali/public-api/object/ref-object.h>
+
#include <string>
namespace Dali
/**
* @brief A class WebEngineRequestInterceptor for intercepting http request.
*/
-class WebEngineRequestInterceptor
+class WebEngineRequestInterceptor : public RefObject
{
public:
/**
/**
* @brief Returns request url.
*
- * @return url on success or empty on failure
+ * @return url if succeeded or empty otherwise
*/
virtual std::string GetUrl() const = 0;
/**
+ * @brief Returns http headers.
+ *
+ * @return headers if succeeded or empty otherwise
+ */
+ virtual Dali::Property::Map GetHeaders() const = 0;
+
+ /**
+ * @brief Returns http method.
+ *
+ * @return method if succeeded or empty otherwise
+ */
+ virtual std::string GetMethod() const = 0;
+
+ /**
* @brief Ignores request.
+ * @note After this call, any further calls result in undefined behavior.
+ * This function can be called only INSIDE Dali::WebEngineContext::WebEngineRequestInterceptedCallback.
*
- * @return true on success or false on failure
+ * @return true if succeeded or false otherwise
*/
virtual bool Ignore() = 0;
* @param[in] statusCode Status code of response
* @param[in] customStatusText Status code of response
*
- * @return true if succeeded or false if failed
+ * @return true if succeeded or false otherwise
*/
virtual bool SetResponseStatus(int statusCode, const std::string& customStatusText) = 0;
* @param[in] fieldName Key of response header
* @param[in] fieldValue Value of response header
*
- * @return true if succeeded or false if failed
+ * @return true if succeeded or false otherwise
*/
virtual bool AddResponseHeader(const std::string& fieldName, const std::string& fieldValue) = 0;
/**
+ * @brief Adds HTTP headers to response.
+ *
+ * @param[in] headers Headers of response
+ *
+ * @return true if succeeded or false otherwise
+ */
+ virtual bool AddResponseHeaders(const Dali::Property::Map& headers) = 0;
+
+ /**
* @brief Writes whole response body at once.
*
* @param[in] body Contents of response
- * @param[in] length Length of Contents of response
+ * @param[in] length Length of contents of response
*
- * @return true if succeeded or false if failed
+ * @return true if succeeded or false otherwise
*/
virtual bool AddResponseBody(const std::string& body, uint32_t length) = 0;
+
+ /**
+ * @brief Writes whole response at once.
+ *
+ * @param[in] headers Headers of response
+ * @param[in] body Contents of response
+ * @param[in] length Length of contents of response
+ *
+ * @return true if succeeded or false otherwise
+ */
+ virtual bool AddResponse(const std::string& headers, const std::string& body, uint32_t length) = 0;
+
+ /**
+ * @brief Writes a part of response body.
+ * @note If this function returns false, handling the request is done.
+ * Any further calls result in undefined behavior.
+ * User should always check return value, because response to this request might not be needed any more,
+ * and function can return false even though user still has data to write.
+ * This function can be called only OUTSIDE Dali::WebEngineContext::WebEngineRequestInterceptedCallback.
+ *
+ * @param[in] chunk Chunks of response
+ * @param[in] length Length of chunks of response
+ *
+ * @return true if succeeded or false otherwise
+ */
+ virtual bool WriteResponseChunk(const std::string& chunk, uint32_t length) = 0;
};
+using WebEngineRequestInterceptorPtr = Dali::IntrusivePtr<WebEngineRequestInterceptor>;
+
} // namespace Dali
#endif // DALI_WEB_ENGINE_REQUEST_INTERCEPTOR_H
#include <dali/devel-api/adaptor-framework/web-engine-http-auth-handler.h>
#include <dali/devel-api/adaptor-framework/web-engine-load-error.h>
#include <dali/devel-api/adaptor-framework/web-engine-policy-decision.h>
-#include <dali/devel-api/adaptor-framework/web-engine-request-interceptor.h>
#include <dali/devel-api/adaptor-framework/web-engine-settings.h>
#include <dali/internal/web-engine/common/web-engine-impl.h>
GetImplementation(*this).RegisterFormRepostDecidedCallback(callback);
}
-void WebEngine::RegisterRequestInterceptorCallback(Dali::WebEnginePlugin::WebEngineRequestInterceptorCallback callback)
-{
- GetImplementation(*this).RegisterRequestInterceptorCallback(callback);
-}
-
void WebEngine::RegisterConsoleMessageReceivedCallback(Dali::WebEnginePlugin::WebEngineConsoleMessageReceivedCallback callback)
{
GetImplementation(*this).RegisterConsoleMessageReceivedCallback(callback);
void RegisterFormRepostDecidedCallback(Dali::WebEnginePlugin::WebEngineFormRepostDecidedCallback callback);
/**
- * @brief Callback to be called when http request need be intercepted.
- *
- * @param[in] callback
- */
- void RegisterRequestInterceptorCallback(Dali::WebEnginePlugin::WebEngineRequestInterceptorCallback callback);
-
- /**
* @brief Callback to be called when console message will be logged.
*
* @param[in] callback
GetImplementation(window).EnableFloatingMode(enable);
}
+void IncludeInputRegion(Window window, const Rect<int>& inputRegion)
+{
+ GetImplementation(window).IncludeInputRegion(inputRegion);
+}
+
+void ExcludeInputRegion(Window window, const Rect<int>& inputRegion)
+{
+ GetImplementation(window).ExcludeInputRegion(inputRegion);
+}
+
} // namespace DevelWindow
} // namespace Dali
*/
DALI_ADAPTOR_API void EnableFloatingMode(Window window, bool enable);
+/**
+ * @brief Includes input region.
+ *
+ * This function inlcudes input regions.
+ * It can be used multiple times and supports multiple regions.
+ * It means input region will be extended.
+ *
+ * This input is related to mouse and touch event.
+ * If device has touch screen, this function is useful.
+ * Otherwise device does not have that, we can use it after connecting mouse to the device.
+ *
+ * @param[in] window The window instance.
+ * @param[in] inputRegion The added region to accept input events.
+ */
+DALI_ADAPTOR_API void IncludeInputRegion(Window window, const Rect<int>& inputRegion);
+
+/**
+ * @brief Excludes input region.
+ *
+ * This function excludes input regions.
+ * It can be used multiple times and supports multiple regions.
+ * It means input region will be reduced.
+ * Nofice, should be set input area by IncludeInputRegion() before this function is used.
+ *
+ * This input is related to mouse and touch event.
+ * If device has touch screen, this function is useful.
+ * Otherwise device does not have that, we can use it after connecting mouse to the device.
+ *
+ * @param[in] window The window instance.
+ * @param[in] inputRegion The subtracted region to except input events.
+ */
+DALI_ADAPTOR_API void ExcludeInputRegion(Window window, const Rect<int>& inputRegion);
+
} // namespace DevelWindow
} // namespace Dali
Adaptor::~Adaptor()
{
+ Accessibility::Bridge::GetCurrentBridge()->ApplicationHidden();
Accessibility::Bridge::GetCurrentBridge()->Terminate();
// Ensure stop status
void Application::QuitFromMainLoop()
{
+ Accessibility::Bridge::GetCurrentBridge()->ApplicationHidden();
Accessibility::Bridge::GetCurrentBridge()->Terminate();
mAdaptor->Stop();
gl->GenBuffers(1, &mBufferId);
context->BindBuffer(GL_ARRAY_BUFFER, mBufferId);
- gl->BufferData(GL_ARRAY_BUFFER, mCreateInfo.size, nullptr, GL_STATIC_DRAW);
+ gl->BufferData(GL_ARRAY_BUFFER, GLsizeiptr(mCreateInfo.size), nullptr, GL_STATIC_DRAW);
}
void Buffer::DestroyResource()
}
}
-} // namespace Dali::Graphics::GLES
\ No newline at end of file
+} // namespace Dali::Graphics::GLES
if(!buffer->IsCPUAllocated())
{
buffer->Bind(BufferUsage::VERTEX_BUFFER);
- gl->BufferSubData(GL_ARRAY_BUFFER, mMapBufferInfo.offset, mMapBufferInfo.size, mMappedPointer);
+ gl->BufferSubData(GL_ARRAY_BUFFER, mMapBufferInfo.offset, GLsizeiptr(mMapBufferInfo.size), mMappedPointer);
}
}
// TODO:
}
-} // namespace Dali::Graphics::GLES
\ No newline at end of file
+} // namespace Dali::Graphics::GLES
// @TODO: trashing vertex binding, better find target that is rarely used
buffer->Bind(Graphics::BufferUsage::VERTEX_BUFFER);
void* ptr = nullptr;
- ptr = gl->MapBufferRange(GL_ARRAY_BUFFER, mMapBufferInfo.offset, mMapBufferInfo.size, GL_MAP_WRITE_BIT);
+ ptr = gl->MapBufferRange(GL_ARRAY_BUFFER, mMapBufferInfo.offset, GLsizeiptr(mMapBufferInfo.size), GL_MAP_WRITE_BIT);
mMappedPointer = ptr;
}
return mMappedPointer;
// TODO:
}
-} // namespace Dali::Graphics::GLES
\ No newline at end of file
+} // namespace Dali::Graphics::GLES
return GL_TEXTURE_2D;
}
-const char* NativeImageSourceAndroid::GetCustomFragmentPrefix() const
-{
- return nullptr;
-}
-
bool NativeImageSourceAndroid::ApplyNativeFragmentShader(std::string& shader)
{
return false;
int GetTextureTarget() const override;
/**
- * @copydoc Dali::NativeImageSource::GetCustomFragmentPrefix()
- */
- const char* GetCustomFragmentPrefix() const override;
-
- /**
* @copydoc Dali::NativeImageSource::ApplyNativeFragmentShader()
*/
bool ApplyNativeFragmentShader(std::string& shader) override;
{
}
-const char* NativeImageSourceQueueAndroid::GetCustomFragmentPrefix() const
-{
- return nullptr;
-}
-
bool NativeImageSourceQueueAndroid::ApplyNativeFragmentShader(std::string& shader)
{
return false;
}
/**
- * @copydoc Dali::NativeImageInterface::GetCustomFragmentPrefix()
- */
- const char* GetCustomFragmentPrefix() const override;
-
- /**
* @copydoc Dali::NativeImageInterface::ApplyNativeFragmentShader()
*/
bool ApplyNativeFragmentShader(std::string& shader) override;
return 0;
}
-const char* NativeBitmapBuffer::GetCustomFragmentPrefix() const
-{
- return nullptr;
-}
-
bool NativeBitmapBuffer::ApplyNativeFragmentShader(std::string& shader)
{
return false;
int GetTextureTarget() const override;
/**
- * @copydoc Dali::NativeImageInterface::GetCustomFragmentPrefix()
- */
- const char* GetCustomFragmentPrefix() const override;
-
- /**
* @copydoc Dali::NativeImageInterface::ApplyNativeFragmentShader()
*/
bool ApplyNativeFragmentShader(std::string& shader) override;
virtual int GetTextureTarget() const = 0;
/**
- * @copydoc Dali::NativeImageSource::GetCustomFragmentPrefix()
- */
- virtual const char* GetCustomFragmentPrefix() const = 0;
-
- /**
* @copydoc Dali::NativeImageSource::ApplyNativeFragmentShader()
*/
virtual bool ApplyNativeFragmentShader(std::string& shader) = 0;
virtual int GetTextureTarget() const = 0;
/**
- * @copydoc Dali::NativeImageInterface::GetCustomFragmentPrefix()
- */
- virtual const char* GetCustomFragmentPrefix() const = 0;
-
- /**
* @copydoc Dali::NativeImageInterface::ApplyNativeFragmentShader()
*/
virtual bool ApplyNativeFragmentShader(std::string& shader) = 0;
{
}
-const char* NativeImageSourceCocoa::GetCustomFragmentPrefix() const
-{
- return nullptr;
-}
-
bool NativeImageSourceCocoa::ApplyNativeFragmentShader(std::string& shader)
{
return false;
bool RequiresBlending() const override;
/**
- * @copydoc Dali::NativeImageInterface::GetCustomFragmentPrefix()
- */
- const char* GetCustomFragmentPrefix() const override;
-
- /**
* @copydoc Dali::NativeImageInterface::ApplyNativeFragmentShader()
*/
bool ApplyNativeFragmentShader(std::string& shader) override;
{
namespace
{
-const char* FRAGMENT_PREFIX = "#extension GL_OES_EGL_image_external:require\n";
const char* SAMPLER_TYPE = "samplerExternalOES";
// clang-format off
}
}
-const char* NativeImageSourceTizen::GetCustomFragmentPrefix() const
-{
- return FRAGMENT_PREFIX;
-}
-
bool NativeImageSourceTizen::ApplyNativeFragmentShader(std::string& shader)
{
return mEglGraphics->ApplyNativeFragmentShader(shader, SAMPLER_TYPE);
}
/**
- * @copydoc Dali::NativeImageInterface::GetCustomFragmentPrefix()
- */
- const char* GetCustomFragmentPrefix() const override;
-
- /**
* @copydoc Dali::NativeImageInterface::ApplyNativeFragmentShader(std::string& shader)
*/
bool ApplyNativeFragmentShader(std::string& shader) override;
{
#define TBM_SURFACE_QUEUE_SIZE 3
-const char* FRAGMENT_PREFIX = "#extension GL_OES_EGL_image_external:require\n";
const char* SAMPLER_TYPE = "samplerExternalOES";
// clang-format off
}
}
-const char* NativeImageSourceQueueTizen::GetCustomFragmentPrefix() const
-{
- return FRAGMENT_PREFIX;
-}
-
bool NativeImageSourceQueueTizen::ApplyNativeFragmentShader(std::string& shader)
{
return mEglGraphics->ApplyNativeFragmentShader(shader, SAMPLER_TYPE);
}
/**
- * @copydoc Dali::NativeImageInterface::GetCustomFragmentPrefix()
- */
- const char* GetCustomFragmentPrefix() const override;
-
- /**
* @copydoc Dali::NativeImageInterface::ApplyNativeFragmentShader()
*/
bool ApplyNativeFragmentShader(std::string& shader) override;
return GL_TEXTURE_2D;
}
-const char* NativeImageSourceX::GetCustomFragmentPrefix() const
-{
- return nullptr;
-}
-
bool NativeImageSourceX::ApplyNativeFragmentShader(std::string& shader)
{
return false;
int GetTextureTarget() const override;
/**
- * @copydoc Dali::NativeImageSource::GetCustomFragmentPrefix()
- */
- const char* GetCustomFragmentPrefix() const override;
-
- /**
* @copydoc Dali::NativeImageSource::ApplyNativeFragmentShader()
*/
bool ApplyNativeFragmentShader(std::string& shader) override;
{
}
-const char* NativeImageSourceQueueX::GetCustomFragmentPrefix() const
-{
- return nullptr;
-}
-
bool NativeImageSourceQueueX::ApplyNativeFragmentShader(std::string& shader)
{
return false;
int GetTextureTarget() const override;
/**
- * @copydoc Dali::NativeImageInterface::GetCustomFragmentPrefix()
- */
- const char* GetCustomFragmentPrefix() const override;
-
- /**
* @copydoc Dali::NativeImageInterface::ApplyNativeFragmentShader()
*/
bool ApplyNativeFragmentShader(std::string& shader) override;
{
}
-const char* NativeImageSourceWin::GetCustomFragmentPrefix() const
-{
- return nullptr;
-}
-
bool NativeImageSourceWin::ApplyNativeFragmentShader(std::string& shader)
{
return false;
}
/**
- * @copydoc Dali::NativeImageInterface::GetCustomFragmentPrefix()
- */
- const char* GetCustomFragmentPrefix() const override;
-
- /**
* @copydoc Dali::NativeImageInterface::ApplyNativeFragmentShader()
*/
bool ApplyNativeFragmentShader(std::string& shader) override;
#include <dali/devel-api/adaptor-framework/web-engine-http-auth-handler.h>
#include <dali/devel-api/adaptor-framework/web-engine-load-error.h>
#include <dali/devel-api/adaptor-framework/web-engine-policy-decision.h>
-#include <dali/devel-api/adaptor-framework/web-engine-request-interceptor.h>
#include <dali/devel-api/adaptor-framework/web-engine-settings.h>
#include <dali/internal/system/common/environment-variables.h>
#include <dali/public-api/adaptor-framework/native-image-source.h>
mPlugin->RegisterFormRepostDecidedCallback(callback);
}
-void WebEngine::RegisterRequestInterceptorCallback(Dali::WebEnginePlugin::WebEngineRequestInterceptorCallback callback)
-{
- mPlugin->RegisterRequestInterceptorCallback(callback);
-}
-
void WebEngine::RegisterConsoleMessageReceivedCallback(Dali::WebEnginePlugin::WebEngineConsoleMessageReceivedCallback callback)
{
mPlugin->RegisterConsoleMessageReceivedCallback(callback);
void RegisterFormRepostDecidedCallback(Dali::WebEnginePlugin::WebEngineFormRepostDecidedCallback callback);
/**
- * @copydoc Dali::WebEngine::RegisterRequestInterceptorCallback()
- */
- void RegisterRequestInterceptorCallback(Dali::WebEnginePlugin::WebEngineRequestInterceptorCallback callback);
-
- /**
@copydoc Dali::WebEngine::RegisterConsoleMessageReceivedCallback()
*/
void RegisterConsoleMessageReceivedCallback(Dali::WebEnginePlugin::WebEngineConsoleMessageReceivedCallback callback);
return false;
}
+void WindowBaseAndroid::IncludeInputRegion(const Rect<int>& inputRegion)
+{
+}
+
+void WindowBaseAndroid::ExcludeInputRegion(const Rect<int>& inputRegion)
+{
+}
+
} // namespace Adaptor
} // namespace Internal
*/
bool IsFloatingModeEnabled() const override;
+ /**
+ * @copydoc Dali::Internal::Adaptor::WindowBase::IncludeInputRegion()
+ */
+ void IncludeInputRegion(const Rect<int>& inputRegion) override;
+
+ /**
+ * @copydoc Dali::Internal::Adaptor::WindowBase::ExcludeInputRegion()
+ */
+ void ExcludeInputRegion(const Rect<int>& inputRegion) override;
+
private:
/**
* Second stage initialization
*/
virtual void ImeWindowReadyToRender() = 0;
+ /**
+ * @brief Includes input region.
+ * @param[in] inputRegion The added region to accept input events.
+ */
+ virtual void IncludeInputRegion(const Rect<int>& inputRegion) = 0;
+
+ /**
+ * @brief Excludes input region.
+ * @param[in] inputRegion The subtracted region to except input events.
+ */
+ virtual void ExcludeInputRegion(const Rect<int>& inputRegion) = 0;
+
// Signals
/**
mWindowBase->EnableFloatingMode(enable);
}
+void Window::IncludeInputRegion(const Rect<int>& inputRegion)
+{
+ mWindowBase->IncludeInputRegion(inputRegion);
+}
+
+void Window::ExcludeInputRegion(const Rect<int>& inputRegion)
+{
+ mWindowBase->ExcludeInputRegion(inputRegion);
+}
+
} // namespace Adaptor
} // namespace Internal
*/
void EnableFloatingMode(bool enable);
+ /**
+ * @copydoc Dali::DevelWindow::IncludeInputRegion()
+ */
+ void IncludeInputRegion(const Rect<int>& inputRegion);
+
+ /**
+ * @copydoc Dali::DevelWindow::ExcludeInputRegion()
+ */
+ void ExcludeInputRegion(const Rect<int>& inputRegion);
+
private:
/**
* @brief Enumeration for orietation mode.
*/
bool IsFloatingModeEnabled() const override;
+ /**
+ * @copydoc Dali::Internal::Adaptor::WindowBase::IncludeInputRegion()
+ */
+ void IncludeInputRegion(const Rect<int>& inputRegion) override;
+
+ /**
+ * @copydoc Dali::Internal::Adaptor::WindowBase::ExcludeInputRegion()
+ */
+ void ExcludeInputRegion(const Rect<int>& inputRegion) override;
+
private:
// Undefined
WindowBaseCocoa(const WindowBaseCocoa&) = delete;
return false;
}
+void WindowBaseCocoa::IncludeInputRegion(const Rect<int>& inputRegion)
+{
+}
+
+void WindowBaseCocoa::ExcludeInputRegion(const Rect<int>& inputRegion)
+{
+}
+
} // namespace Dali::Internal::Adaptor
@implementation CocoaView
return false;
}
+void WindowBaseEcoreWl::IncludeInputRegion(const Rect<int>& inputRegion)
+{
+}
+
+void WindowBaseEcoreWl::ExcludeInputRegion(const Rect<int>& inputRegion)
+{
+}
+
} // namespace Adaptor
} // namespace Internal
*/
bool IsFloatingModeEnabled() const override;
+ /**
+ * @copydoc Dali::Internal::Adaptor::WindowBase::IncludeInputRegion()
+ */
+ void IncludeInputRegion(const Rect<int>& inputRegion) override;
+
+ /**
+ * @copydoc Dali::Internal::Adaptor::WindowBase::ExcludeInputRegion()
+ */
+ void ExcludeInputRegion(const Rect<int>& inputRegion) override;
+
private:
/**
* Second stage initialization
return ecore_wl2_window_floating_mode_get(mEcoreWindow);
}
+void WindowBaseEcoreWl2::IncludeInputRegion(const Rect<int>& inputRegion)
+{
+ Eina_Rectangle rect;
+ rect.x = inputRegion.x;
+ rect.y = inputRegion.y;
+ rect.w = inputRegion.width;
+ rect.h = inputRegion.height;
+
+ ecore_wl2_window_input_rect_add(mEcoreWindow, &rect);
+ ecore_wl2_window_commit(mEcoreWindow, EINA_TRUE);
+}
+
+void WindowBaseEcoreWl2::ExcludeInputRegion(const Rect<int>& inputRegion)
+{
+ Eina_Rectangle rect;
+ rect.x = inputRegion.x;
+ rect.y = inputRegion.y;
+ rect.w = inputRegion.width;
+ rect.h = inputRegion.height;
+
+ ecore_wl2_window_input_rect_subtract(mEcoreWindow, &rect);
+ ecore_wl2_window_commit(mEcoreWindow, EINA_TRUE);
+}
+
} // namespace Adaptor
} // namespace Internal
*/
bool IsFloatingModeEnabled() const override;
+ /**
+ * @copydoc Dali::Internal::Adaptor::WindowBase::IncludeInputRegion()
+ */
+ void IncludeInputRegion(const Rect<int>& inputRegion) override;
+
+ /**
+ * @copydoc Dali::Internal::Adaptor::WindowBase::ExcludeInputRegion()
+ */
+ void ExcludeInputRegion(const Rect<int>& inputRegion) override;
+
private:
/**
* Second stage initialization
return false;
}
+void WindowBaseEcoreX::IncludeInputRegion(const Rect<int>& inputRegion)
+{
+}
+
+void WindowBaseEcoreX::ExcludeInputRegion(const Rect<int>& inputRegion)
+{
+}
+
} // namespace Adaptor
} // namespace Internal
*/
bool IsFloatingModeEnabled() const override;
+ /**
+ * @copydoc Dali::Internal::Adaptor::WindowBase::IncludeInputRegion()
+ */
+ void IncludeInputRegion(const Rect<int>& inputRegion) override;
+
+ /**
+ * @copydoc Dali::Internal::Adaptor::WindowBase::ExcludeInputRegion()
+ */
+ void ExcludeInputRegion(const Rect<int>& inputRegion) override;
+
private:
/**
* Second stage initialization
return false;
}
+void WindowBaseWin::IncludeInputRegion(const Rect<int>& inputRegion)
+{
+}
+
+void WindowBaseWin::ExcludeInputRegion(const Rect<int>& inputRegion)
+{
+}
+
} // namespace Adaptor
} // namespace Internal
*/
bool IsFloatingModeEnabled() const override;
+ /**
+ * @copydoc Dali::Internal::Adaptor::WindowBase::IncludeInputRegion()
+ */
+ void IncludeInputRegion(const Rect<int>& inputRegion) override;
+
+ /**
+ * @copydoc Dali::Internal::Adaptor::WindowBase::ExcludeInputRegion()
+ */
+ void ExcludeInputRegion(const Rect<int>& inputRegion) override;
+
private:
/**
* Second stage initialization
return mImpl->GetTextureTarget();
}
-const char* NativeImageSource::GetCustomFragmentPrefix() const
-{
- return mImpl->GetCustomFragmentPrefix();
-}
-
bool NativeImageSource::ApplyNativeFragmentShader(std::string& shader)
{
return mImpl->ApplyNativeFragmentShader(shader);
int GetTextureTarget() const override;
/**
- * @copydoc Dali::NativeImageInterface::GetCustomFragmentPrefix()
- */
- const char* GetCustomFragmentPrefix() const override;
-
- /**
* @copydoc Dali::NativeImageInterface::ApplyNativeFragmentShader()
*/
bool ApplyNativeFragmentShader(std::string& shader) override;
{
const unsigned int ADAPTOR_MAJOR_VERSION = 2;
const unsigned int ADAPTOR_MINOR_VERSION = 0;
-const unsigned int ADAPTOR_MICRO_VERSION = 40;
+const unsigned int ADAPTOR_MICRO_VERSION = 41;
const char* const ADAPTOR_BUILD_DATE = __DATE__ " " __TIME__;
#ifdef DEBUG_ENABLED
Name: dali2-adaptor
Summary: The DALi Tizen Adaptor
-Version: 2.0.40
+Version: 2.0.41
Release: 1
Group: System/Libraries
License: Apache-2.0 and BSD-3-Clause and MIT