March 2013
Beginner to intermediate
580 pages
16h 11m
English
Earlier in the chapter you used the include tag to include a row of RemoteButtons multiple times (into the same layout).
It works in the obvious way:
<include layout="@layout/some_partial_layout"/>
The above include will include the contents of the layout file whose resource ID is @layout/some_partial_layout.
You can use include to reduce duplication in a single layout, as you did earlier in this chapter,
or you can use it to reduce duplication between layouts. If you have some chunk of a layout
that occurs in two or more layouts, you can just create that chunk as a layout and include it wherever it is needed.
Then when you need to update it, you only have to do it in a single place.
There are two more ...
Read now
Unlock full access