protected void showShareDialog() { if (mShareDialog == null) { mShareDialog = new GUIStoryShareDialog(this); mShareDialog.setOnShareClickListener(mOnClickListener); } mShareDialog.show(); }
protected void showCommentDialog() { if (mCommentDialog != null) { mCommentDialog = null; } if (mShareDialog != null && mShareDialog.isShowing()) { mShareDialog.dismiss(); } FragmentManager fm = getSupportFragmentManager(); VideoStoryDetailFragment frag = (VideoStoryDetailFragment) fm.findFragmentByTag(getFragmentTag(mPager.getCurrentItem())); mCommentDialog = new GUIStoryCommentDialog(this); mCommentDialog.setStoryId(mStoryId); mCommentDialog.setStoryTitle(frag.getStoryTitle()); // FIXME: refresh story comment on Dialog's dismiss. mCommentDialog.setOnDismissListener(mOnDialogDismissListener); mCommentDialog.show(); }
protected void socialShare(int networkId, int isstatus) { if (mShareDialog != null && mShareDialog.isShowing()) { mShareDialog.dismiss(); } // Collect story's information String[] data = null; FragmentManager fm = getSupportFragmentManager(); VideoStoryDetailFragment frag = (VideoStoryDetailFragment) fm.findFragmentByTag(getFragmentTag(mPager.getCurrentItem())); if (frag != null) { data = frag.getShareContent().split("%2C"); GKIMLog.lf(null, 0, TAG + "=>socialShare: " + data.length); } if (data != null && data.length >= 3) { // Progress SNS's strategy SocialHelper helper = SocialHelper.getInstance(this, networkId); // FIXME: add callback for listening result. helper.post(data, isstatus); } }