@@ -8,7 +8,6 @@ import android.content.Intent
88import android.content.SharedPreferences
99import android.content.pm.PackageManager
1010import android.content.pm.ResolveInfo
11- import android.content.res.ColorStateList
1211import android.content.res.Configuration
1312import android.graphics.Color
1413import android.graphics.drawable.Drawable
@@ -249,15 +248,47 @@ import java.util.*
249248 val dialogLayout: View = inflater.inflate(R .layout.help_alert, null )
250249
251250 // Founding BUTTONS
251+ val text = dialogLayout.findViewById<TextView >(R .id.text_help)
252+ val power = dialogLayout.findViewById<TextView >(R .id.power_assistant)
253+ val power1 = dialogLayout.findViewById<TextView >(R .id.power_1)
254+ val power2 = dialogLayout.findViewById<TextView >(R .id.power_2)
255+ val power3 = dialogLayout.findViewById<TextView >(R .id.power_3)
256+ val power4 = dialogLayout.findViewById<TextView >(R .id.power_4)
257+ val power5 = dialogLayout.findViewById<TextView >(R .id.power_5)
258+ val power6 = dialogLayout.findViewById<TextView >(R .id.power_6)
259+ val bubble = dialogLayout.findViewById<TextView >(R .id.bubble_manager)
260+ val bubble1 = dialogLayout.findViewById<TextView >(R .id.bubble_1)
261+ val bubble2 = dialogLayout.findViewById<TextView >(R .id.bubble_2)
262+ val bubble3 = dialogLayout.findViewById<TextView >(R .id.bubble_3)
263+
252264 val cancel = dialogLayout.findViewById<Button >(R .id.cancel_help)
253265 val enable = dialogLayout.findViewById<Button >(R .id.enable_help)
254266 val goAccess = dialogLayout.findViewById<Button >(R .id.go_access)
267+
255268 val imageBubble1 = dialogLayout.findViewById<ImageView >(R .id.image_bubble_1)
256269 val imageBubble2 = dialogLayout.findViewById<ImageView >(R .id.image_bubble_2)
257270 val imageBubble3 = dialogLayout.findViewById<ImageView >(R .id.image_bubble_3)
258271 val imagePower1 = dialogLayout.findViewById<ImageView >(R .id.image_power_1)
259272 val imagePower2 = dialogLayout.findViewById<ImageView >(R .id.image_power_2)
260273
274+ // Changing COLOR THEME
275+ cancel.setTextColor(getButtonColor())
276+ enable.setTextColor(getButtonColor())
277+ goAccess.setTextColor(getButtonColor())
278+ text.setTextColor(getButtonColor())
279+ power.setTextColor(getButtonColor())
280+ power1.setTextColor(getButtonColor())
281+ power2.setTextColor(getButtonColor())
282+ power3.setTextColor(getButtonColor())
283+ power4.setTextColor(getButtonColor())
284+ power5.setTextColor(getButtonColor())
285+ power6.setTextColor(getButtonColor())
286+ bubble.setTextColor(getButtonColor())
287+ bubble1.setTextColor(getButtonColor())
288+ bubble2.setTextColor(getButtonColor())
289+ bubble3.setTextColor(getButtonColor())
290+
291+
261292 // Configuring pictures
262293 if (nightMode){
263294 imagePower1.setImageResource(R .drawable.ic_power_assistant_1_dark)
@@ -380,11 +411,17 @@ import java.util.*
380411 val dialogLayout: View = inflater.inflate(R .layout.settings_alert, null )
381412
382413 // Founding BUTTONS
414+ val text = dialogLayout.findViewById<TextView >(R .id.text_settings)
383415 val cancel = dialogLayout.findViewById<Button >(R .id.cancel_settings)
384416 val settings = dialogLayout.findViewById<Button >(R .id.settings_app)
385417 val clear = dialogLayout.findViewById<Button >(R .id.clear_data)
386418
387-
419+ // Changing COLOR THEME
420+ cancel.setTextColor(getButtonColor())
421+ settings.setTextColor(getButtonColor())
422+ clear.setTextColor(getButtonColor())
423+ text.setTextColor(getButtonColor())
424+
388425 // Configuring BACKGROUND
389426 configBack(dialogLayout)
390427
@@ -429,9 +466,14 @@ import java.util.*
429466 val dialogLayout: View = inflater.inflate(R .layout.add_button_alert, null )
430467
431468 // Founding BUTTONS AND EDITTEXTS
469+ val text = dialogLayout.findViewById<TextView >(R .id.text_add_button)
432470 val appRecycler = dialogLayout.findViewById<RecyclerView >(R .id.app_recycler)
433471 val cancel = dialogLayout.findViewById<Button >(R .id.cancel_add_button)
434472
473+ // Changing COLOR THEME
474+ cancel.setTextColor(getButtonColor())
475+ text.setTextColor(getButtonColor())
476+
435477 // Configuring FOR ALL APPS
436478 val mutableLabels = getAppsLabel()
437479 val mutablePackages = getAppsPackage()
@@ -478,10 +520,16 @@ import java.util.*
478520 val dialogLayout: View = inflater.inflate(R .layout.change_controls_alert, null )
479521
480522 // Founding BUTTONS and RECYCLERVIEW
523+ val text = dialogLayout.findViewById<TextView >(R .id.text_change_controls)
481524 val changeRecycler = dialogLayout.findViewById<RecyclerView >(R .id.change_recycler)
482525 val ok = dialogLayout.findViewById<Button >(R .id.ok_change_position)
483526 val cancel = dialogLayout.findViewById<Button >(R .id.cancel_change_position)
484527
528+ // Change COLOR THEME
529+ ok.setTextColor(getButtonColor())
530+ cancel.setTextColor(getButtonColor())
531+ text.setTextColor(getButtonColor())
532+
485533 // Init values for CONTROLS
486534 val mutableNames = mutableListOf<String >()
487535 val mutableIcons = mutableListOf<Int >()
@@ -581,11 +629,19 @@ import java.util.*
581629 val dialogLayout: View = inflater.inflate(R .layout.bubble_manager_alert, null )
582630
583631 // Founding BUTTONS
632+ val text = dialogLayout.findViewById<TextView >(R .id.text_bubble_manager)
584633 val cancel = dialogLayout.findViewById<Button >(R .id.cancel_bubble_manager)
585634 val enable = dialogLayout.findViewById<Button >(R .id.enable)
586635 val changePosition = dialogLayout.findViewById<Button >(R .id.change_position)
587636 val addButton = dialogLayout.findViewById<Button >(R .id.add_button)
588637
638+ // Changing COLOR THEME
639+ cancel.setTextColor(getButtonColor())
640+ enable.setTextColor(getButtonColor())
641+ changePosition.setTextColor(getButtonColor())
642+ addButton.setTextColor(getButtonColor())
643+ text.setTextColor(getButtonColor())
644+
589645 // Configuring BACKGROUND
590646 configBack(dialogLayout)
591647
@@ -648,9 +704,15 @@ import java.util.*
648704 val dialogLayout: View = inflater.inflate(R .layout.weather_director_alert, null )
649705
650706 // Founding BUTTONS
707+ val text = dialogLayout.findViewById<TextView >(R .id.text_weather_director)
651708 val cancel = dialogLayout.findViewById<Button >(R .id.cancel_weather_director)
652709 val changeCity = dialogLayout.findViewById<Button >(R .id.city_change)
653710
711+ // Changing COLOR THEME
712+ cancel.setTextColor(getButtonColor())
713+ changeCity.setTextColor(getButtonColor())
714+ text.setTextColor(getButtonColor())
715+
654716 // Configuring BACKGROUND
655717 configBack(dialogLayout)
656718
@@ -693,6 +755,11 @@ import java.util.*
693755 val cancelCity = dialogLayoutCity.findViewById<Button >(R .id.cancel_change_city)
694756 val changeCityField = dialogLayoutCity.findViewById<TextInputEditText >(R .id.city_field_in)
695757
758+ // Changing COLOR THEME
759+ okCity.setTextColor(getButtonColor())
760+ cancelCity.setTextColor(getButtonColor())
761+ changeCityField.setTextColor(getButtonColor())
762+
696763 // Configuring BACKGROUND for CITY
697764 configBack(dialogLayoutCity)
698765
@@ -749,8 +816,13 @@ import java.util.*
749816 val dialogLayout: View = inflater.inflate(R .layout.first_change_alert, null )
750817
751818 // Founding BUTTONS
819+ val text = dialogLayout.findViewById<TextView >(R .id.text_how_change)
752820 val understand = dialogLayout.findViewById<Button >(R .id.understand_first_change)
753821
822+ // Changing COLOR THEME
823+ understand.setTextColor(getButtonColor())
824+ text.setTextColor(getButtonColor())
825+
754826 // Configuring BACKGROUND
755827 configBack(dialogLayout)
756828
@@ -775,8 +847,13 @@ import java.util.*
775847 val dialogLayout: View = inflater.inflate(R .layout.first_change_city_alert, null )
776848
777849 // Founding BUTTONS
850+ val text = dialogLayout.findViewById<TextView >(R .id.text_how_change_city)
778851 val understand = dialogLayout.findViewById<Button >(R .id.understand_first_change_city_alert)
779852
853+ // Changing COLOR THEME
854+ understand.setTextColor(getButtonColor())
855+ text.setTextColor(getButtonColor())
856+
780857 // Configuring BACKGROUND
781858 configBack(dialogLayout)
782859
@@ -801,8 +878,13 @@ import java.util.*
801878 val dialogLayout: View = inflater.inflate(R .layout.first_add_button_alert, null )
802879
803880 // Founding BUTTONS
881+ val text = dialogLayout.findViewById<TextView >(R .id.text_how_add)
804882 val understand = dialogLayout.findViewById<Button >(R .id.understand_first_add)
805883
884+ // Changing COLOR THEME
885+ understand.setTextColor(getButtonColor())
886+ text.setTextColor(getButtonColor())
887+
806888 // Configuring BACKGROUND
807889 configBack(dialogLayout)
808890
@@ -827,11 +909,19 @@ import java.util.*
827909 val dialogLayout: View = inflater.inflate(R .layout.welcome_alert, null )
828910
829911 // Founding BUTTONS
912+ val text = dialogLayout.findViewById<TextView >(R .id.text_welcome)
913+ val subText = dialogLayout.findViewById<TextView >(R .id.text_subwelcome)
830914 val power = dialogLayout.findViewById<Button >(R .id.bubble)
831915 val bubble = dialogLayout.findViewById<Button >(R .id.power)
832916 val logo = dialogLayout.findViewById<ImageView >(R .id.image_logo_shorttasks)
833917 val imageBubble = dialogLayout.findViewById<ImageView >(R .id.image_bubble)
834918
919+ // Changing COLOR THEME
920+ power.setTextColor(getButtonColor())
921+ bubble.setTextColor(getButtonColor())
922+ text.setTextColor(getButtonColor())
923+ subText.setTextColor(getButtonColor())
924+
835925 // Configuring pictures
836926 if (nightMode){
837927 logo.setImageResource(R .drawable.ic_logo_main_dark)
@@ -869,12 +959,24 @@ import java.util.*
869959 val dialogLayout: View = inflater.inflate(R .layout.bubble_manager_first_alert, null )
870960
871961 // Founding BUTTONS
962+ val text = dialogLayout.findViewById<TextView >(R .id.bubble_manager)
963+ val bubble1 = dialogLayout.findViewById<TextView >(R .id.bubble_1)
964+ val bubble2 = dialogLayout.findViewById<TextView >(R .id.bubble_2)
965+ val bubble3 = dialogLayout.findViewById<TextView >(R .id.bubble_3)
872966 val understand = dialogLayout.findViewById<Button >(R .id.cancel_bubble_manager_first)
873967 val enable = dialogLayout.findViewById<Button >(R .id.enable_first)
874968 val image1 = dialogLayout.findViewById<ImageView >(R .id.image_bubble_1_first)
875969 val image2 = dialogLayout.findViewById<ImageView >(R .id.image_bubble_2_first)
876970 val image3 = dialogLayout.findViewById<ImageView >(R .id.image_bubble_3_first)
877971
972+ // Changing COLOR THEME
973+ understand.setTextColor(getButtonColor())
974+ enable.setTextColor(getButtonColor())
975+ text.setTextColor(getButtonColor())
976+ bubble1.setTextColor(getButtonColor())
977+ bubble2.setTextColor(getButtonColor())
978+ bubble3.setTextColor(getButtonColor())
979+
878980 // Configuring pictures
879981 if (nightMode){
880982 image1.setImageResource(R .drawable.ic_bubble_manager_1_dark)
@@ -912,11 +1014,29 @@ import java.util.*
9121014 val dialogLayout: View = inflater.inflate(R .layout.power_assistant_first_alert, null )
9131015
9141016 // Founding BUTTONS
1017+ val power = dialogLayout.findViewById<TextView >(R .id.power_assistant)
1018+ val power1 = dialogLayout.findViewById<TextView >(R .id.power_1)
1019+ val power2 = dialogLayout.findViewById<TextView >(R .id.power_2)
1020+ val power3 = dialogLayout.findViewById<TextView >(R .id.power_3)
1021+ val power4 = dialogLayout.findViewById<TextView >(R .id.power_4)
1022+ val power5 = dialogLayout.findViewById<TextView >(R .id.power_5)
1023+ val power6 = dialogLayout.findViewById<TextView >(R .id.power_6)
9151024 val understand = dialogLayout.findViewById<Button >(R .id.cancel_power_assistant_first)
9161025 val go = dialogLayout.findViewById<Button >(R .id.go_access_first)
9171026 val image1 = dialogLayout.findViewById<ImageView >(R .id.image_power_1_first)
9181027 val image2 = dialogLayout.findViewById<ImageView >(R .id.image_power_2_first)
9191028
1029+ // Changing COLOR THEME
1030+ understand.setTextColor(getButtonColor())
1031+ go.setTextColor(getButtonColor())
1032+ power.setTextColor(getButtonColor())
1033+ power1.setTextColor(getButtonColor())
1034+ power2.setTextColor(getButtonColor())
1035+ power3.setTextColor(getButtonColor())
1036+ power4.setTextColor(getButtonColor())
1037+ power5.setTextColor(getButtonColor())
1038+ power6.setTextColor(getButtonColor())
1039+
9201040 // Configuring pictures
9211041 if (nightMode){
9221042 image1.setImageResource(R .drawable.ic_power_assistant_1_dark)
@@ -954,9 +1074,16 @@ import java.util.*
9541074 val dialogLayout: View = inflater.inflate(R .layout.clear_data_allowing_alert, null )
9551075
9561076 // Founding BUTTONS
1077+ val text = dialogLayout.findViewById<TextView >(R .id.text_allow)
1078+ val subText = dialogLayout.findViewById<TextView >(R .id.text_clear)
9571079 val ok = dialogLayout.findViewById<Button >(R .id.ok_clear)
9581080 val cancel = dialogLayout.findViewById<Button >(R .id.cancel_clear)
9591081
1082+ // Changing COLOR THEME
1083+ ok.setTextColor(getButtonColor())
1084+ cancel.setTextColor(getButtonColor())
1085+ text.setTextColor(getButtonColor())
1086+ subText.setTextColor(getButtonColor())
9601087 // Configuring BACKGROUND
9611088 configBack(dialogLayout)
9621089
0 commit comments