mirror of
				https://github.com/SimpleMobileTools/Simple-Flashlight.git
				synced 2025-06-05 21:59:19 +02:00 
			
		
		
		
	fix #55, allow landscape mode
This commit is contained in:
		| @@ -43,6 +43,7 @@ android { | ||||
| dependencies { | ||||
|     implementation 'com.simplemobiletools:commons:3.18.6' | ||||
|     implementation 'com.squareup:otto:1.3.8' | ||||
|     implementation 'com.android.support.constraint:constraint-layout:1.0.2' | ||||
| } | ||||
|  | ||||
| Properties props = new Properties() | ||||
|   | ||||
| @@ -38,7 +38,6 @@ | ||||
|  | ||||
|         <activity | ||||
|             android:name=".activities.MainActivity" | ||||
|             android:screenOrientation="portrait" | ||||
|             android:theme="@style/AppTheme"/> | ||||
|  | ||||
|         <activity | ||||
| @@ -50,9 +49,7 @@ | ||||
|             </intent-filter> | ||||
|         </activity> | ||||
|  | ||||
|         <activity | ||||
|             android:name=".activities.BrightDisplayActivity" | ||||
|             android:screenOrientation="portrait"/> | ||||
|         <activity android:name=".activities.BrightDisplayActivity"/> | ||||
|  | ||||
|         <activity | ||||
|             android:name=".activities.SettingsActivity" | ||||
|   | ||||
| @@ -1,19 +1,29 @@ | ||||
| <?xml version="1.0" encoding="utf-8"?> | ||||
| <LinearLayout | ||||
| <ScrollView | ||||
|     xmlns:android="http://schemas.android.com/apk/res/android" | ||||
|     android:id="@+id/main_holder" | ||||
|     xmlns:app="http://schemas.android.com/apk/res-auto" | ||||
|     android:id="@+id/main_scrollview" | ||||
|     android:layout_width="match_parent" | ||||
|     android:layout_height="match_parent" | ||||
|     android:gravity="center" | ||||
|     android:orientation="vertical" | ||||
|     android:padding="@dimen/activity_margin"> | ||||
|     android:fillViewport="true"> | ||||
|  | ||||
|     <android.support.constraint.ConstraintLayout | ||||
|         android:id="@+id/main_holder" | ||||
|         android:layout_width="match_parent" | ||||
|         android:layout_height="wrap_content"> | ||||
|  | ||||
|         <ImageView | ||||
|             android:id="@+id/toggle_btn" | ||||
|             android:layout_width="@dimen/main_button_size" | ||||
|             android:layout_height="@dimen/main_button_size" | ||||
|             android:layout_marginBottom="@dimen/activity_margin" | ||||
|         android:background="@drawable/circles_big"/> | ||||
|             android:layout_marginTop="@dimen/activity_margin" | ||||
|             android:background="@drawable/circles_big" | ||||
|             app:layout_constraintBottom_toTopOf="@+id/bright_display_btn" | ||||
|             app:layout_constraintEnd_toEndOf="parent" | ||||
|             app:layout_constraintHorizontal_bias="0.5" | ||||
|             app:layout_constraintStart_toStartOf="parent" | ||||
|             app:layout_constraintTop_toTopOf="parent"/> | ||||
|  | ||||
|         <ImageView | ||||
|             android:id="@+id/bright_display_btn" | ||||
| @@ -22,7 +32,12 @@ | ||||
|             android:layout_marginBottom="@dimen/activity_margin" | ||||
|             android:layout_marginTop="@dimen/buttons_margin" | ||||
|             android:background="@drawable/ic_bright_display" | ||||
|         android:padding="@dimen/activity_margin"/> | ||||
|             android:padding="@dimen/activity_margin" | ||||
|             app:layout_constraintBottom_toTopOf="@+id/stroboscope_btn" | ||||
|             app:layout_constraintEnd_toEndOf="parent" | ||||
|             app:layout_constraintHorizontal_bias="0.5" | ||||
|             app:layout_constraintStart_toStartOf="parent" | ||||
|             app:layout_constraintTop_toBottomOf="@+id/toggle_btn"/> | ||||
|  | ||||
|         <ImageView | ||||
|             android:id="@+id/stroboscope_btn" | ||||
| @@ -30,7 +45,12 @@ | ||||
|             android:layout_height="wrap_content" | ||||
|             android:layout_marginTop="@dimen/buttons_margin" | ||||
|             android:background="@drawable/ic_stroboscope" | ||||
|         android:padding="@dimen/activity_margin"/> | ||||
|             android:padding="@dimen/activity_margin" | ||||
|             app:layout_constraintBottom_toTopOf="@+id/stroboscope_bar" | ||||
|             app:layout_constraintEnd_toEndOf="parent" | ||||
|             app:layout_constraintHorizontal_bias="0.5" | ||||
|             app:layout_constraintStart_toStartOf="parent" | ||||
|             app:layout_constraintTop_toBottomOf="@+id/bright_display_btn"/> | ||||
|  | ||||
|         <com.simplemobiletools.commons.views.MySeekBar | ||||
|             android:id="@+id/stroboscope_bar" | ||||
| @@ -39,6 +59,12 @@ | ||||
|             android:layout_margin="@dimen/activity_margin" | ||||
|             android:paddingBottom="@dimen/medium_margin" | ||||
|             android:paddingTop="@dimen/medium_margin" | ||||
|         android:visibility="invisible"/> | ||||
|             android:visibility="invisible" | ||||
|             app:layout_constraintBottom_toBottomOf="parent" | ||||
|             app:layout_constraintEnd_toEndOf="parent" | ||||
|             app:layout_constraintHorizontal_bias="0.5" | ||||
|             app:layout_constraintStart_toStartOf="parent" | ||||
|             app:layout_constraintTop_toBottomOf="@+id/stroboscope_btn"/> | ||||
|  | ||||
| </LinearLayout> | ||||
|     </android.support.constraint.ConstraintLayout> | ||||
| </ScrollView> | ||||
|   | ||||
		Reference in New Issue
	
	Block a user