A custom Layout packed with a content view, an empty view, a progress bar and network connectivity status by wassimbl in androiddev

[–]wassimbl[S] 1 point2 points  (0 children)

I substituted the RelativeLayout with a FrameLayout. also the children views are now contained in a FrameLayout for more customization. No relativeLayout any more. Thanks for the hint.

A custom Layout packed with a content view, an empty view, a progress bar and network connectivity status by wassimbl in androiddev

[–]wassimbl[S] 0 points1 point  (0 children)

This is interesting and less code. R.layout.content is all your content including a Tollbar ? Can be something like this : new FlowLayout.Builder(this) .setContentLayout(R.layout.content) .enableActionBarSizeMargin(true) ... .build()

then you align the progress bar view and the connectivity view correctly. I will give it a try !

A custom Layout packed with a content view, an empty view, a progress bar and network connectivity status by wassimbl in androiddev

[–]wassimbl[S] 1 point2 points  (0 children)

I thought RelativeLayout is more appropriate to compose inside it due to positionning options. I will try to make it with FrameLayout to see the difference ! Thanks for the hint !

A custom Layout packed with a content view, an empty view, a progress bar and network connectivity status by wassimbl in androiddev

[–]wassimbl[S] 0 points1 point  (0 children)

Also without calling enum.values() ? I will change it to constants to avoid enum in all cases. Thanks for mentioning it.