if (!settings)
return;
- if (settings->linkEffectEnabled() && hit_test &&
- (hit_test->GetResultContext() &
- tizen_webview::TW_HIT_TEST_RESULT_CONTEXT_LINK)) {
- sound_effect::playLinkEffect();
+ if (!hit_test)
+ return;
+
+ if (hit_test->GetResultContext() &
+ tizen_webview::TW_HIT_TEST_RESULT_CONTEXT_LINK) {
+ if (settings->linkEffectEnabled())
+ sound_effect::playLinkEffect();
#if defined(TIZEN_CONTENTS_DETECTION)
- } else if (settings->detectContentsAutomatically() && hit_test &&
- (hit_test->GetResultContext() &
- tizen_webview::TW_HIT_TEST_RESULT_CONTEXT_TEXT)) {
+ rwhv->OnContentsDetected(hit_test->GetLinkUri());
+ } else if (settings->detectContentsAutomatically() &&
+ (hit_test->GetResultContext() &
+ tizen_webview::TW_HIT_TEST_RESULT_CONTEXT_TEXT)) {
rwhv->DetectContentOnPosition(x, y);
#endif
}