[Tizen] Add more logs for later Accessibility issue 68/288668/1 accepted/tizen/6.0/unified/20230222.072533 submit/tizen_6.0/20230221.090300
authorSeoyeon Kim <seoyeon2.kim@samsung.com>
Tue, 21 Feb 2023 08:51:25 +0000 (17:51 +0900)
committerSeoyeon Kim <seoyeon2.kim@samsung.com>
Tue, 21 Feb 2023 08:53:39 +0000 (17:53 +0900)
- To make debugging much easier, put DALI_LOG_ERROR logs in Accessibility code.
 (In fact, it has nothing to do with Error)

Change-Id: I9c4a629a90fd5ebf76b7781547a83c33f932c4f6
Signed-off-by: Seoyeon Kim <seoyeon2.kim@samsung.com>
dali/internal/accessibility/common/accessibility-adaptor-impl.cpp
dali/internal/window-system/common/event-handler.cpp

index 68e32cfea53f4acbb1d23e4c883b426d1e4cd8e0..80b678b836b50c139f88183d2e6fed8ee4978060 100644 (file)
@@ -66,20 +66,21 @@ void AccessibilityAdaptor::EnableAccessibility()
 #ifndef DALI_PROFILE_UBUNTU
   system_settings_get_value_bool( SYSTEM_SETTINGS_KEY_ACCESSIBILITY_TTS, &accessibilityState );
 #endif
-  if(accessibilityState == false)
+  if (accessibilityState == false)
   {
     DALI_LOG_ERROR("The Current Accessibility system cannot run. \n");
     return;
   }
 
-  if(mIsEnabled == false)
+  if (mIsEnabled == false)
   {
     mIsEnabled = true;
 
     SetFocusedActorPosition(Dali::Vector2(-1.0f, -1.0f));
 
-    if( mActionHandler )
+    if (mActionHandler)
     {
+      DALI_LOG_ERROR("[FYI] AccessibilityAdaptor::EnableAccessibility() \n");
       mActionHandler->ChangeAccessibilityStatus();
     }
   }
@@ -87,17 +88,18 @@ void AccessibilityAdaptor::EnableAccessibility()
 
 void AccessibilityAdaptor::DisableAccessibility()
 {
-  if(mIsEnabled == true)
+  if (mIsEnabled == true)
   {
     mIsEnabled = false;
 
-    if( mActionHandler )
+    if (mActionHandler)
     {
+      DALI_LOG_ERROR("[FYI] AccessibilityAdaptor::DisableAccessibility() \n");
       mActionHandler->ChangeAccessibilityStatus();
     }
 
     // Destroy the TtsPlayer if exists.
-    if ( Adaptor::IsAvailable() )
+    if (Adaptor::IsAvailable())
     {
       Dali::Adaptor& adaptor = Dali::Adaptor::Get();
       Adaptor& adaptorImpl = Adaptor::GetImplementation( adaptor );
index 820b2a032985b99aeb411633aa42faafcc381b8a..1429ada98a6b2d9375021609f783ecc9c1e0fc87 100755 (executable)
@@ -313,6 +313,7 @@ void EventHandler::OnAccessibilityNotification( const WindowBase::AccessibilityI
     {
       // Ignore tap gesture - it should be handled by another window (possibly in another application),
       // for which the resource ID matches with the one stored in AccessibilityInfo.
+      DALI_LOG_ERROR("Ignore Single tap gesture because the gesture should be handled by other window. \n");
       return;
     }
   }
@@ -333,9 +334,12 @@ void EventHandler::OnAccessibilityNotification( const WindowBase::AccessibilityI
   {
     // When other apps, which are not implemented by DALi, are on top of Apps application,
     // no event should be occurred on Apps because it's disabled by force already.
+    DALI_LOG_ERROR("Currently, all DALi applications do not receive any events because another app, which is not implemented by DALi, is at the top of the layer. \n");
     return;
   }
 
+  DALI_LOG_ERROR("[FYI] Accessibility gesture value : %d, state : %d \n", info.gestureValue, info.state);
+
   // When gesture is ONE_FINGER_SINGLE_TAP, the gesture value is 15.
   // When the state is aborted, the state of accessibility info is 3.
   if( info.gestureValue == 15 && info.state == 3 )
@@ -606,19 +610,19 @@ void EventHandler::OnAccessibilityQuickpanelChanged( const unsigned char& info )
       ( info & ( 1 << QUICKPANEL_TYPE_SYSTEM_DEFAULT ) ) ) // QuickPanel is shown
   {
     // dali apps should be disabled.
-    DALI_LOG_INFO( gSelectionEventLogFilter, Debug::General, "OnAccessibilityQuickpanelChanged: Quickpanel show -> DisableAccessibility \n" );
+    DALI_LOG_ERROR("[FYI] Quickpanel show -> DisableAccessibility \n");
     accessibilityAdaptor->DisableAccessibility();
   }
   else if( info & ( 1 << QUICKPANEL_TYPE_APPS_MENU ) ) // Only Apps menu (dali application) is shown
   {
     if( !accessibilityAdaptor->IsForcedEnable() ) // It is not in case of that an application controls the accessibility status itself
     {
-      DALI_LOG_INFO( gSelectionEventLogFilter, Debug::General, "OnAccessibilityQuickpanelChanged: Only Apps show, but not forced dali -> DisableAccessibility \n" );
+      DALI_LOG_ERROR("[FYI] Only Apps show, but not forced dali -> DisableAccessibility \n");
       accessibilityAdaptor->DisableAccessibility();
     }
     else
     {
-      DALI_LOG_INFO( gSelectionEventLogFilter, Debug::General, "OnAccessibilityQuickpanelChanged: Only Apps show and it is a forced dali -> EnableAccessibility \n" );
+      DALI_LOG_ERROR("[FYI] Only Apps show and it is a forced dali -> EnableAccessibility \n");
       accessibilityAdaptor->EnableAccessibility();
     }
   }