Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • B BoomMenu
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 114
    • Issues 114
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 5
    • Merge requests 5
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • 黄伟平
  • BoomMenu
  • Wiki
  • Basic Usage

Basic Usage · Changes

Page history
Updated Basic Usage (markdown) authored Mar 28, 2017 by Weiping Huang's avatar Weiping Huang
Hide whitespace changes
Inline Side-by-side
Basic-Usage.md
View page @ b0f29aa4
How to use BMB in just several lines of code? How to use BMB in just several lines of code?
###Create BMB ### Create BMB
Add BMB in .xml file. Add BMB in .xml file.
...@@ -55,7 +55,7 @@ Or in .xml: ...@@ -55,7 +55,7 @@ Or in .xml:
app:bmb_buttonPlaceEnum="buttonPlace_sc_3_3" app:bmb_buttonPlaceEnum="buttonPlace_sc_3_3"
``` ```
###Add Builders ### Add Builders
You have set attributes for BMB itself, now add builders for customizing boom-buttons to BMB. There are 4 different builders for the 4 kinds of boom-buttons above. For instance, use `SimpleCircleButton.Builder` for `ButtonEnum.SimpleCircle`. Click the links for 4 kinds of buttons above to find out how to use builders. You have set attributes for BMB itself, now add builders for customizing boom-buttons to BMB. There are 4 different builders for the 4 kinds of boom-buttons above. For instance, use `SimpleCircleButton.Builder` for `ButtonEnum.SimpleCircle`. Click the links for 4 kinds of buttons above to find out how to use builders.
``` ```
...@@ -67,7 +67,7 @@ for (int i = 0; i < bmb.getButtonPlaceEnum().buttonNumber(); i++) { ...@@ -67,7 +67,7 @@ for (int i = 0; i < bmb.getButtonPlaceEnum().buttonNumber(); i++) {
And now your BMB is ready for a boom. And now your BMB is ready for a boom.
###Attention ### Attention
You must keep the number of piece-place-enum, number of button-place-enum and number of builders being the same. You must keep the number of piece-place-enum, number of button-place-enum and number of builders being the same.
The name of piece-place-enum is XXX_N_M, where XXX is name(DOT or HAM), N is number and M represents different types. Similarly, the name of button-place-enum is YYY_N_M. You must keep the first N equals to the second one. But you needn't keep the two M same(The code above is an example: DOT_3_1 and SC_3_3). The name of piece-place-enum is XXX_N_M, where XXX is name(DOT or HAM), N is number and M represents different types. Similarly, the name of button-place-enum is YYY_N_M. You must keep the first N equals to the second one. But you needn't keep the two M same(The code above is an example: DOT_3_1 and SC_3_3).
......
Clone repository
Chapters
  1. Basic Usage
  2. Simple Circle Button
  3. Text Inside Circle Button
  4. Text Outside Circle Button
  5. Ham Button
  6. Share Style
  7. Button Place Alignments
  8. Different Ways to Boom
  9. Ease Animations for Buttons
  10. Different Order for Buttons
  11. Other Animations Attributes for Buttons
  12. Click Event and Listener
  13. Control BMB
  14. Use BMB in Action Bar
  15. Use BMB in List
  16. Use BMB in Fragment
  17. Attributes for BMB or Pieces on BMB
  18. Cache Optimization & Boom Area
  19. Version History
  20. Structure for BMB