Skip to content

Commit 996da4f

Browse files
committed
Adjust drawer inflation button position
1 parent 098072c commit 996da4f

File tree

4 files changed

+14
-21
lines changed

4 files changed

+14
-21
lines changed

.idea/deploymentTargetDropDown.xml

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/workspace.xml

Lines changed: 2 additions & 12 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

app/src/main/java/com/autocrop/activities/main/fragments/flowfield/views/FlowFieldDrawerLayout.kt

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,18 @@ import androidx.core.view.GravityCompat
77
import androidx.drawerlayout.widget.DrawerLayout
88
import androidx.fragment.app.findFragment
99
import com.autocrop.activities.main.fragments.flowfield.FlowFieldFragment
10+
import com.autocrop.utils.android.extensions.ifNotInEditMode
1011
import com.w2sv.autocrop.databinding.FragmentFlowfieldBinding
1112

1213
class FlowFieldDrawerLayout(context: Context, attributeSet: AttributeSet): DrawerLayout(context, attributeSet){
1314
override fun onAttachedToWindow() {
1415
super.onAttachedToWindow()
1516

16-
findFragment<FlowFieldFragment>()
17-
.binding
18-
.setAssociatedButtons()
17+
ifNotInEditMode {
18+
findFragment<FlowFieldFragment>()
19+
.binding
20+
.setAssociatedButtons()
21+
}
1922
}
2023

2124
private fun FragmentFlowfieldBinding.setAssociatedButtons(){

app/src/main/res/layout/fragment_flowfield.xml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@
3232
android:id="@+id/navigation_drawer_button_burger"
3333
android:layout_height="28dp"
3434
android:layout_width="28dp"
35-
android:layout_marginStart="25dp"
36-
android:layout_marginTop="25dp"
35+
android:layout_marginStart="35dp"
36+
android:layout_marginTop="35dp"
3737
android:contentDescription="@string/main_menu_toggle"
3838

3939
android:background="@drawable/ic_baseline_menu_24"/>
@@ -42,8 +42,8 @@
4242
android:id="@+id/navigation_drawer_button_arrow"
4343
android:layout_height="28dp"
4444
android:layout_width="28dp"
45-
android:layout_marginStart="25dp"
46-
android:layout_marginTop="25dp"
45+
android:layout_marginStart="35dp"
46+
android:layout_marginTop="35dp"
4747
android:contentDescription="@string/main_menu_toggle"
4848

4949
android:background="@drawable/ic_baseline_arrow_back_24"
@@ -67,7 +67,7 @@
6767

6868
<com.autocrop.activities.main.fragments.flowfield.views.FlowFieldNavigationView
6969
android:layout_alignTop="@+id/navigation_drawer_button_burger"
70-
android:layout_marginTop="50dp"
70+
android:layout_marginTop="60dp"
7171

7272
android:id="@+id/navigation_view"
7373
android:layout_height="match_parent"

0 commit comments

Comments
 (0)