README.md
1
2 Android WatchViewStub Sample
3 ===================================
4
5 This sample demonstrates how to specify different layouts for round and rectangular screens.
6
7 Introduction
8 ------------
9
10 It is a basic sample that displays a round layout on a round watch and a rectangular one on a
11 rectangular watch.
12
13 The corresponding layout is being inflated by the system. This sample shows a way to handle
14 this programatically by using a `WatchViewStub.OnLayoutInflateListener`.
15
16 Pre-requisites
17 --------------
18
19 - Android SDK 26
20 - Android Build Tools v26.0.1
21 - Android Support Repository
22
23 Screenshots
24 -------------
25
26 <img src="screenshots/watch_view_stub_rectangular.png" height="400" alt="Screenshot"/> <img src="screenshots/watch_view_stub_round.png" height="400" alt="Screenshot"/>
27
28 Getting Started
29 ---------------
30
31 This sample uses the Gradle build system. To build this project, use the
32 "gradlew build" command or use "Import Project" in Android Studio.
33
34 Support
35 -------
36
37 - Google+ Community: https://plus.google.com/communities/105153134372062985968
38 - Stack Overflow: http://stackoverflow.com/questions/tagged/android
39
40 If you've found an error in this sample, please file an issue:
41 https://github.com/googlesamples/android-WatchViewStub
42
43 Patches are encouraged, and may be submitted by forking this project and
44 submitting a pull request through GitHub. Please see CONTRIBUTING.md for more details.
45
46 License
47 -------
48
49 Copyright 2017 The Android Open Source Project, Inc.
50
51 Licensed to the Apache Software Foundation (ASF) under one or more contributor
52 license agreements. See the NOTICE file distributed with this work for
53 additional information regarding copyright ownership. The ASF licenses this
54 file to you under the Apache License, Version 2.0 (the "License"); you may not
55 use this file except in compliance with the License. You may obtain a copy of
56 the License at
57
58 http://www.apache.org/licenses/LICENSE-2.0
59
60 Unless required by applicable law or agreed to in writing, software
61 distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
62 WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
63 License for the specific language governing permissions and limitations under
64 the License.
65