import android.app.Activity;
import android.app.AlertDialog;
import android.content.DialogInterface;
+import android.view.View;
/**
* Handles generic products which are not books.
private static final int[] buttons = {
R.string.button_product_search,
R.string.button_web_search,
- R.string.button_google_shopper,
- R.string.button_custom_product_search,
+ R.string.button_custom_product_search
};
public ProductResultHandler(Activity activity, ParsedResult result, Result rawResult) {
super(activity, result, rawResult);
+ showGoogleShopperButton(new View.OnClickListener() {
+ public void onClick(View view) {
+ ProductParsedResult productResult = (ProductParsedResult) getResult();
+ openGoogleShopper(productResult.getNormalizedProductID());
+ }
+ });
}
@Override
webSearch(productResult.getNormalizedProductID());
break;
case 2:
- openGoogleShopper(productResult.getNormalizedProductID());
- break;
- case 3:
openURL(fillInCustomSearchURL(productResult.getNormalizedProductID()));
break;
}