Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ protected void onCreate(Bundle savedInstanceState) {
mTitleTextView.setText(R.string.app_name);
mActionBar.setCustomView(actionBar);
mActionBar.setDisplayShowCustomEnabled(true);
((Toolbar) actionBar.getParent()).setContentInsetsAbsolute(0,0);
((Toolbar) actionBar.getParent()).setContentInsetsAbsolute(0, 0);

BoomMenuButton leftBmb = (BoomMenuButton) actionBar.findViewById(R.id.action_bar_left_bmb);
BoomMenuButton rightBmb = (BoomMenuButton) actionBar.findViewById(R.id.action_bar_right_bmb);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ public void onStopTrackingTouch(SeekBar seekBar) {

}
});
topMarginSeekText = (TextView)findViewById(R.id.top_margin_text);
topMarginSeekText = (TextView) findViewById(R.id.top_margin_text);
topMarginSeekText.setText("Top margin = " + topMarginSeekBar.getProgress() + " pixel(s)");
}

Expand All @@ -105,7 +105,7 @@ public void onStopTrackingTouch(SeekBar seekBar) {

}
});
bottomMarginSeekText = (TextView)findViewById(R.id.bottom_margin_text);
bottomMarginSeekText = (TextView) findViewById(R.id.bottom_margin_text);
bottomMarginSeekText.setText("Bottom margin = " + bottomMarginSeekBar.getProgress() + " pixel(s)");
}

Expand All @@ -131,7 +131,7 @@ public void onStopTrackingTouch(SeekBar seekBar) {

}
});
leftMarginSeekText = (TextView)findViewById(R.id.left_margin_text);
leftMarginSeekText = (TextView) findViewById(R.id.left_margin_text);
leftMarginSeekText.setText("Left margin = " + leftMarginSeekBar.getProgress() + " pixel(s)");
}

Expand All @@ -157,7 +157,7 @@ public void onStopTrackingTouch(SeekBar seekBar) {

}
});
rightMarginSeekText = (TextView)findViewById(R.id.right_margin_text);
rightMarginSeekText = (TextView) findViewById(R.id.right_margin_text);
rightMarginSeekText.setText("Right margin = " + rightMarginSeekBar.getProgress() + " pixel(s)");
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,12 @@ protected void onCreate(Bundle savedInstanceState) {
listView.setAdapter(new MyAdapter());
listView.setOnItemClickListener(
new AdapterView.OnItemClickListener() {
@Override
public void onItemClick(AdapterView<?> parent, View view, int position, long id) {
BoomMenuButton bmb = (BoomMenuButton)view.findViewById(R.id.bmb1);
bmb.boom();
}
});
@Override
public void onItemClick(AdapterView<?> parent, View view, int position, long id) {
BoomMenuButton bmb = (BoomMenuButton) view.findViewById(R.id.bmb1);
bmb.boom();
}
});
}

static class MyAdapter extends BaseAdapter {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,8 @@ public void onItemClick(AdapterView<?> parent, View view, int position, long id)

private List<String> getData() {
List<String> data = new ArrayList<>();
for (int i = 0; i < OrderEnum.values().length - 1; i++) data.add(OrderEnum.values()[i] + "");
for (int i = 0; i < OrderEnum.values().length - 1; i++)
data.add(OrderEnum.values()[i] + "");
return data;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_share);

initBmb(bmb1 = (BoomMenuButton)findViewById(R.id.bmb1));
initBmb(bmb2 = (BoomMenuButton)findViewById(R.id.bmb2));
initBmb(bmb3 = (BoomMenuButton)findViewById(R.id.bmb3));
initBmb(bmb1 = (BoomMenuButton) findViewById(R.id.bmb1));
initBmb(bmb2 = (BoomMenuButton) findViewById(R.id.bmb2));
initBmb(bmb3 = (BoomMenuButton) findViewById(R.id.bmb3));

bmb1.setShareLineLength(45);
bmb1.setShareLineWidth(5);
Expand Down Expand Up @@ -72,7 +72,7 @@ public void onStopTrackingTouch(SeekBar seekBar) {

}
});
showDelaySeekText = (TextView)findViewById(R.id.show_delay_text);
showDelaySeekText = (TextView) findViewById(R.id.show_delay_text);
showDelaySeekText.setText("Show delay = " + showDelaySeekBar.getProgress() + " ms");
}

Expand Down Expand Up @@ -100,7 +100,7 @@ public void onStopTrackingTouch(SeekBar seekBar) {

}
});
showDurationSeekText = (TextView)findViewById(R.id.show_duration_text);
showDurationSeekText = (TextView) findViewById(R.id.show_duration_text);
showDurationSeekText.setText("Show duration = " + showDurationSeekBar.getProgress() + " ms");
}

Expand Down Expand Up @@ -128,7 +128,7 @@ public void onStopTrackingTouch(SeekBar seekBar) {

}
});
hideDelaySeekText = (TextView)findViewById(R.id.hide_delay_text);
hideDelaySeekText = (TextView) findViewById(R.id.hide_delay_text);
hideDelaySeekText.setText("Hide delay = " + hideDelaySeekBar.getProgress() + " ms");
}

Expand Down Expand Up @@ -156,7 +156,7 @@ public void onStopTrackingTouch(SeekBar seekBar) {

}
});
hideDurationSeekText = (TextView)findViewById(R.id.hide_duration_text);
hideDurationSeekText = (TextView) findViewById(R.id.hide_duration_text);
hideDurationSeekText.setText("Hide duration = " + hideDurationSeekBar.getProgress() + " ms");
}
}
5 changes: 2 additions & 3 deletions app/src/main/res/layout/activity_boom_example.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,14 @@
<ListView
android:id="@+id/list_view"
android:layout_width="match_parent"
android:layout_height="match_parent"/>
android:layout_height="match_parent" />

<com.nightonke.boommenu.BoomMenuButton
android:id="@+id/bmb"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_alignParentRight="true"
android:layout_alignParentEnd="true"
/>
android:layout_alignParentEnd="true" />

</RelativeLayout>
29 changes: 10 additions & 19 deletions app/src/main/res/layout/activity_button_place_alignment.xml
Original file line number Diff line number Diff line change
Expand Up @@ -19,63 +19,55 @@
android:id="@+id/top_margin_seek"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:progress="0"
/>
android:progress="0" />

<TextView
android:id="@+id/top_margin_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center_vertical|end"
/>
android:gravity="center_vertical|end" />

<SeekBar
android:id="@+id/bottom_margin_seek"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:progress="0"
/>
android:progress="0" />

<TextView
android:id="@+id/bottom_margin_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center_vertical|end"
/>
android:gravity="center_vertical|end" />

<SeekBar
android:id="@+id/left_margin_seek"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:progress="0"
/>
android:progress="0" />

<TextView
android:id="@+id/left_margin_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center_vertical|end"
/>
android:gravity="center_vertical|end" />

<SeekBar
android:id="@+id/right_margin_seek"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:progress="0"
/>
android:progress="0" />

<TextView
android:id="@+id/right_margin_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center_vertical|end"
/>
android:gravity="center_vertical|end" />

<ListView
android:id="@+id/list_view"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1"/>
android:layout_weight="1" />

</LinearLayout>

Expand All @@ -86,7 +78,6 @@
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_alignParentRight="true"
android:layout_alignParentEnd="true"
/>
android:layout_alignParentEnd="true" />

</RelativeLayout>
11 changes: 5 additions & 6 deletions app/src/main/res/layout/activity_control.xml
Original file line number Diff line number Diff line change
Expand Up @@ -16,25 +16,25 @@
android:id="@+id/boom"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="BOOM!"/>
android:text="BOOM!" />

<Button
android:id="@+id/reboom"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="Re-BOOM!"/>
android:text="Re-BOOM!" />

<Button
android:id="@+id/boom_immediately"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="BOOM immediately!"/>
android:text="BOOM immediately!" />

<Button
android:id="@+id/reboom_immediately"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="Re-BOOM immediately!"/>
android:text="Re-BOOM immediately!" />

<FrameLayout
android:layout_width="match_parent"
Expand All @@ -49,8 +49,7 @@
app:bmb_buttonEnum="simpleCircle"
app:bmb_piecePlaceEnum="piecePlace_dot_9_1"
app:bmb_buttonPlaceEnum="buttonPlace_sc_9_1"
app:bmb_boomInWholeScreen="false"
/>
app:bmb_boomInWholeScreen="false" />

</FrameLayout>

Expand Down
27 changes: 9 additions & 18 deletions app/src/main/res/layout/activity_ease.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,7 @@
app:bmb_piecePlaceEnum="piecePlace_dot_9_1"
app:bmb_buttonPlaceEnum="buttonPlace_sc_9_1"
app:bmb_showDuration="1000"
app:bmb_hideDuration="500"
/>
app:bmb_hideDuration="500" />

<com.nightonke.boommenu.BoomMenuButton
android:id="@+id/bmb2"
Expand All @@ -41,8 +40,7 @@
app:bmb_showRotateEaseEnum="outExpo"
app:bmb_hideMoveEaseEnum="inExpo"
app:bmb_hideScaleEaseEnum="inExpo"
app:bmb_hideRotateEaseEnum="inExpo"
/>
app:bmb_hideRotateEaseEnum="inExpo" />

<com.nightonke.boommenu.BoomMenuButton
android:id="@+id/bmb3"
Expand All @@ -61,8 +59,7 @@
app:bmb_showRotateEaseEnum="outBounce"
app:bmb_hideMoveEaseEnum="outBounce"
app:bmb_hideScaleEaseEnum="outBounce"
app:bmb_hideRotateEaseEnum="outBounce"
/>
app:bmb_hideRotateEaseEnum="outBounce" />

<com.nightonke.boommenu.BoomMenuButton
android:id="@+id/bmb4"
Expand All @@ -83,8 +80,7 @@
app:bmb_hideScaleEaseEnum="inElastic"
app:bmb_hideRotateEaseEnum="inElastic"
app:bmb_showDelay="0"
app:bmb_hideDelay="0"
/>
app:bmb_hideDelay="0" />

<com.nightonke.boommenu.BoomMenuButton
android:id="@+id/bmb5"
Expand All @@ -103,8 +99,7 @@
app:bmb_showRotateEaseEnum="inSine"
app:bmb_hideMoveEaseEnum="inSine"
app:bmb_hideScaleEaseEnum="inSine"
app:bmb_hideRotateEaseEnum="inSine"
/>
app:bmb_hideRotateEaseEnum="inSine" />

<com.nightonke.boommenu.BoomMenuButton
android:id="@+id/bmb6"
Expand All @@ -122,8 +117,7 @@
app:bmb_showRotateEaseEnum="inCirc"
app:bmb_hideMoveEaseEnum="inCirc"
app:bmb_hideScaleEaseEnum="inCirc"
app:bmb_hideRotateEaseEnum="inCirc"
/>
app:bmb_hideRotateEaseEnum="inCirc" />

<com.nightonke.boommenu.BoomMenuButton
android:id="@+id/bmb7"
Expand All @@ -142,8 +136,7 @@
app:bmb_showRotateEaseEnum="outCirc"
app:bmb_hideMoveEaseEnum="outCirc"
app:bmb_hideScaleEaseEnum="outCirc"
app:bmb_hideRotateEaseEnum="outCirc"
/>
app:bmb_hideRotateEaseEnum="outCirc" />

<com.nightonke.boommenu.BoomMenuButton
android:id="@+id/bmb8"
Expand All @@ -163,8 +156,7 @@
app:bmb_hideMoveEaseEnum="inBack"
app:bmb_hideScaleEaseEnum="inBack"
app:bmb_hideRotateEaseEnum="inBack"
app:bmb_orderEnum="orderDefault"
/>
app:bmb_orderEnum="orderDefault" />

<com.nightonke.boommenu.BoomMenuButton
android:id="@+id/bmb9"
Expand All @@ -181,7 +173,6 @@
app:bmb_hideScaleEaseEnum="inOutQuad"
app:bmb_hideRotateEaseEnum="inOutQuad"
app:bmb_showDelay="0"
app:bmb_hideDelay="0"
/>
app:bmb_hideDelay="0" />

</RelativeLayout>
2 changes: 1 addition & 1 deletion app/src/main/res/layout/activity_fragment.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@
<android.support.v4.view.ViewPager
android:id="@+id/view_pager"
android:layout_width="match_parent"
android:layout_height="match_parent"/>
android:layout_height="match_parent" />

</RelativeLayout>
5 changes: 2 additions & 3 deletions app/src/main/res/layout/activity_ham_button.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,14 @@
<ListView
android:id="@+id/list_view"
android:layout_width="match_parent"
android:layout_height="match_parent"/>
android:layout_height="match_parent" />

<com.nightonke.boommenu.BoomMenuButton
android:id="@+id/bmb"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_alignParentRight="true"
android:layout_alignParentEnd="true"
/>
android:layout_alignParentEnd="true" />

</RelativeLayout>
5 changes: 2 additions & 3 deletions app/src/main/res/layout/activity_list_view.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,11 @@
android:paddingLeft="@dimen/activity_horizontal_margin"
android:paddingRight="@dimen/activity_horizontal_margin"
android:paddingTop="@dimen/activity_vertical_margin"
tools:context="com.nightonke.boommenusample.ListViewActivity" >
tools:context="com.nightonke.boommenusample.ListViewActivity">

<ListView
android:id="@+id/list_view"
android:layout_width="match_parent"
android:layout_height="match_parent"
/>
android:layout_height="match_parent" />

</RelativeLayout>
Loading