Skip to content

Commit

Permalink
examples: Android helloworld to pass Google lint (#10518)
Browse files Browse the repository at this point in the history
These changes allow the Android helloworld example to pass the lint
checks of the Google internal build system.
  • Loading branch information
temawi authored Aug 24, 2023
1 parent 3fad521 commit 5559d54
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,13 @@ protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_helloworld);
sendButton = (Button) findViewById(R.id.send_button);
sendButton.setOnClickListener(
new View.OnClickListener() {
@Override
public void onClick(View v) {
sendMessage(v);
}
});
hostEdit = (EditText) findViewById(R.id.host_edit_text);
portEdit = (EditText) findViewById(R.id.port_edit_text);
messageEdit = (EditText) findViewById(R.id.message_edit_text);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
android:layout_weight="2"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:inputType="text"
android:hint="Enter Host" />
<EditText
android:id="@+id/port_edit_text"
Expand All @@ -28,13 +29,13 @@
android:id="@+id/message_edit_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:inputType="text"
android:hint="Enter message to send" />

<Button
android:id="@+id/send_button"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:onClick="sendMessage"
android:text="Send Grpc Request" />

<TextView
Expand Down

0 comments on commit 5559d54

Please sign in to comment.