diff options
| author | Andrew Solovay <asolovay@google.com> | 2015-03-13 11:45:24 -0700 |
|---|---|---|
| committer | Andrew Solovay <asolovay@google.com> | 2015-03-13 12:46:37 -0700 |
| commit | a8b5b2512f0fc56394a6906ecbebde4becedf015 (patch) | |
| tree | 9a21c4504d3ec5bcdfcb633523379eaa2d7657b5 | |
| parent | 42bb44dbf5bffc5d3fcf89eacfd5c561dbe8095c (diff) | |
| download | frameworks_base-a8b5b2512f0fc56394a6906ecbebde4becedf015.zip frameworks_base-a8b5b2512f0fc56394a6906ecbebde4becedf015.tar.gz frameworks_base-a8b5b2512f0fc56394a6906ecbebde4becedf015.tar.bz2 | |
docs: Fixed broken image link, and broke long lines in code samples
While I had gridview open (per the bug), I also checked the other
files in that directory for broken image links (in case this stemmed
from a doc reorg). I didn't find any broken images, but I did find
a couple of code samples that unnecessarily had horizontal scroll
bars, so I fixed those.
See first comment for doc stage location.
bug: 19611361
Change-Id: I983a09aaee5e2b1747376748c1aa46341c31a3c2
| -rw-r--r-- | docs/html/guide/topics/ui/layout/grid.jd | 2 | ||||
| -rw-r--r-- | docs/html/guide/topics/ui/layout/gridview.jd | 9 |
2 files changed, 7 insertions, 4 deletions
diff --git a/docs/html/guide/topics/ui/layout/grid.jd b/docs/html/guide/topics/ui/layout/grid.jd index c2f1321..3474f48 100644 --- a/docs/html/guide/topics/ui/layout/grid.jd +++ b/docs/html/guide/topics/ui/layout/grid.jd @@ -181,7 +181,7 @@ file.</p> <li>Run the application.</li> </ol> <p>You should see the following:</p> -<img src="images/hello-tablelayout.png" width="150px" /> +<img src="{@docRoot}guide/topics/ui/images/hello-tablelayout.png" width="150px" /> diff --git a/docs/html/guide/topics/ui/layout/gridview.jd b/docs/html/guide/topics/ui/layout/gridview.jd index a4bf224..13467ae 100644 --- a/docs/html/guide/topics/ui/layout/gridview.jd +++ b/docs/html/guide/topics/ui/layout/gridview.jd @@ -70,8 +70,10 @@ public void onCreate(Bundle savedInstanceState) { gridview.setAdapter(new ImageAdapter(this)); gridview.setOnItemClickListener(new OnItemClickListener() { - public void onItemClick(AdapterView<?> parent, View v, int position, long id) { - Toast.makeText(HelloGridView.this, "" + position, Toast.LENGTH_SHORT).show(); + public void onItemClick(AdapterView<?> parent, View v, + int position, long id) { + Toast.makeText(HelloGridView.this, "" + position, + Toast.LENGTH_SHORT).show(); } }); } @@ -118,7 +120,8 @@ public class ImageAdapter extends BaseAdapter { // create a new ImageView for each item referenced by the Adapter public View getView(int position, View convertView, ViewGroup parent) { ImageView imageView; - if (convertView == null) { // if it's not recycled, initialize some attributes + if (convertView == null) { + // if it's not recycled, initialize some attributes imageView = new ImageView(mContext); imageView.setLayoutParams(new GridView.LayoutParams(85, 85)); imageView.setScaleType(ImageView.ScaleType.CENTER_CROP); |
