Search in sources :

Example 36 with ImageButton

use of android.widget.ImageButton in project neo4j-mobile-android by neo4j-contrib.

the class RelationshipPropertiesActivity method addRelationshipPropertiesListItem.

private void addRelationshipPropertiesListItem(final String key, final Object value) {
    View propertyListItem = inflater.inflate(R.layout.property_listitem, null);
    TextView propertyKeyText = (TextView) propertyListItem.findViewById(R.id.propertyKeyText);
    propertyKeyText.setText(key);
    TextView propertyValueText = (TextView) propertyListItem.findViewById(R.id.propertyValueText);
    propertyValueText.setText("" + value);
    ImageButton propertyEditButton = (ImageButton) propertyListItem.findViewById(R.id.propertyEditButton);
    if (value instanceof String) {
        final String valueString = (String) value;
        propertyEditButton.setOnClickListener(new View.OnClickListener() {

            @Override
            public void onClick(View v) {
                askUpdateProperty(key, valueString);
            }
        });
    } else {
        propertyEditButton.setEnabled(false);
    }
    ImageButton propertyDeleteButton = (ImageButton) propertyListItem.findViewById(R.id.propertyDeleteButton);
    propertyDeleteButton.setOnClickListener(new View.OnClickListener() {

        @Override
        public void onClick(View v) {
            confirmDeletionOfProperty(key, value);
        }
    });
    relationshipPropertiesListLayout.addView(propertyListItem);
}
Also used : ImageButton(android.widget.ImageButton) TextView(android.widget.TextView) ContentView(roboguice.inject.ContentView) InjectView(roboguice.inject.InjectView) TextView(android.widget.TextView) View(android.view.View)

Example 37 with ImageButton

use of android.widget.ImageButton in project Klyph by jonathangerbaud.

the class StreamAdapter2 method attachHolder.

@Override
protected void attachHolder(View view) {
    ImageView authorProfileImage = (ImageView) view.findViewById(R.id.author_profile_image);
    TextView story = (TextView) view.findViewById(R.id.story);
    TextView postTime = (TextView) view.findViewById(R.id.post_time);
    ImageView sharedAuthorProfileImage = (ImageView) view.findViewById(R.id.shared_author_profile_image);
    TextView sharedStory = (TextView) view.findViewById(R.id.shared_story);
    TextView sharedPostTime = (TextView) view.findViewById(R.id.shared_post_time);
    TextView message = (TextView) view.findViewById(R.id.message);
    ImageView postPhoto = (ImageView) view.findViewById(R.id.post_photo);
    ImageView postVideoPlay = (ImageView) view.findViewById(R.id.post_video_play);
    TextView videoTitle = (TextView) view.findViewById(R.id.post_video_title);
    TextView videoUrl = (TextView) view.findViewById(R.id.post_video_url);
    ImageView postPicturePlay = (ImageView) view.findViewById(R.id.post_picture_play);
    ImageView postLinkBackground = (ImageView) view.findViewById(R.id.stream_link_image_background);
    TextView postName = (TextView) view.findViewById(R.id.post_name);
    TextView postCaption = (TextView) view.findViewById(R.id.post_caption);
    TextView postDescription = (TextView) view.findViewById(R.id.post_description);
    HListView streamAlbum = (HListView) view.findViewById(R.id.stream_album);
    ViewGroup streamLink = (ViewGroup) view.findViewById(R.id.stream_link);
    Button likeButton = (Button) view.findViewById(R.id.like_button);
    Button commentButton = (Button) view.findViewById(R.id.comment_button);
    ImageButton shareButton = (ImageButton) view.findViewById(R.id.share_button);
    ImageButton overflowButton = (ImageButton) view.findViewById(R.id.overflow_button);
    ViewGroup buttonBar = (ViewGroup) view.findViewById(R.id.button_bar);
    View buttonBarDivider = (View) view.findViewById(R.id.button_bar_divider);
    StreamHolder holder = new StreamHolder(authorProfileImage, story, postTime, sharedAuthorProfileImage, sharedStory, sharedPostTime, message, postPhoto, postVideoPlay, videoTitle, videoUrl, postPicturePlay, postLinkBackground, postName, postCaption, postDescription, likeButton, commentButton, shareButton, overflowButton, streamAlbum, streamLink, buttonBar, buttonBarDivider);
    setHolder(view, holder);
}
Also used : ImageButton(android.widget.ImageButton) HListView(it.sephiroth.android.library.widget.HListView) ImageButton(android.widget.ImageButton) Button(android.widget.Button) ViewGroup(android.view.ViewGroup) TextView(android.widget.TextView) ImageView(android.widget.ImageView) ImageView(android.widget.ImageView) HListView(it.sephiroth.android.library.widget.HListView) View(android.view.View) TextView(android.widget.TextView) StreamHolder(com.abewy.android.apps.klyph.adapter.holder.StreamHolder)

Example 38 with ImageButton

use of android.widget.ImageButton in project UltimateAndroid by cymcsg.

the class MenuCircleShowingAnimation method addItem.

public void addItem(Drawable drawable, View.OnClickListener onClickListener) {
    ImageButton button = (ImageButton) LayoutInflater.from(context).inflate(R.layout.menu_animation_promoted_action_button, frameLayout, false);
    button.setImageDrawable(drawable);
    button.setOnClickListener(onClickListener);
    promotedActions.add(button);
    frameLayout.addView(button);
    return;
}
Also used : ImageButton(android.widget.ImageButton)

Example 39 with ImageButton

use of android.widget.ImageButton in project UltimateAndroid by cymcsg.

the class MenuCircleShowingAnimation method addMainItem.

public ImageButton addMainItem(Drawable drawable) {
    ImageButton button = (ImageButton) LayoutInflater.from(context).inflate(R.layout.menu_animation_main_promoted_action_button, frameLayout, false);
    button.setImageDrawable(drawable);
    button.setOnClickListener(new View.OnClickListener() {

        @Override
        public void onClick(View view) {
            if (isMenuOpened) {
                closePromotedActions().start();
                isMenuOpened = false;
            } else {
                isMenuOpened = true;
                openPromotedActions().start();
            }
        }
    });
    frameLayout.addView(button);
    mainImageButton = button;
    return button;
}
Also used : ImageButton(android.widget.ImageButton) View(android.view.View)

Example 40 with ImageButton

use of android.widget.ImageButton in project GreenDroid by cyrilmottier.

the class NormalActionBarItem method prepareItemView.

@Override
protected void prepareItemView() {
    super.prepareItemView();
    final ImageButton imageButton = (ImageButton) mItemView.findViewById(R.id.gd_action_bar_item);
    imageButton.setImageDrawable(mDrawable);
    imageButton.setContentDescription(mContentDescription);
}
Also used : ImageButton(android.widget.ImageButton)

Aggregations

ImageButton (android.widget.ImageButton)158 View (android.view.View)112 TextView (android.widget.TextView)87 ImageView (android.widget.ImageView)55 Button (android.widget.Button)27 ListView (android.widget.ListView)25 AdapterView (android.widget.AdapterView)24 OnClickListener (android.view.View.OnClickListener)21 LinearLayout (android.widget.LinearLayout)21 Intent (android.content.Intent)19 RelativeLayout (android.widget.RelativeLayout)13 DialogInterface (android.content.DialogInterface)12 Bundle (android.os.Bundle)11 LayoutInflater (android.view.LayoutInflater)11 EditText (android.widget.EditText)11 ViewGroup (android.view.ViewGroup)10 ArrayList (java.util.ArrayList)10 Builder (android.app.AlertDialog.Builder)7 Drawable (android.graphics.drawable.Drawable)7 RecyclerView (android.support.v7.widget.RecyclerView)7