Code example for Context

Methods: getResources

0
        return this;
    } 
 
    public MenuItem setIcon(int iconRes) {
        mIconResId = iconRes;
        mIconDrawable = mContext.getResources().getDrawable(iconRes);
        return this;
    } 
 
    public MenuItem setIntent(Intent intent) {
        mIntent = intent;
        return this;
    } 
 
    public MenuItem setNumericShortcut(char numericChar) {
        mShortcutNumericChar = numericChar;
        return this;
    } 
 
    public MenuItem setOnMenuItemClickListener(OnMenuItemClickListener menuItemClickListener) {
Connect your IDE to all the code out there  Get Codota for Java