private void btn_RenRen_Tap(object sender, System.Windows.Input.GestureEventArgs e) { RenrenAPI api = App.api; List <APIParameter> param = new List <APIParameter>(); //param.Add(new APIParameter("url", "http://dev.renren.com")); //param.Add(new APIParameter("name", "Becle")); //param.Add(new APIParameter("action_name", "You Can Green The World!")); ////param.Add(new APIParameter("action_link", "http://www.aaronke.co.cc")); ////param.Add(new APIParameter("description"," ")); //param.Add(new APIParameter("caption", "The earth thanks for you contributions!")); //param.Add(new APIParameter("image", "http://www.aaronke.co.cc/ic/img/home/facebook_logo.jpg")); param.Add(new APIParameter("url", "http://dev.renren.com")); param.Add(new APIParameter("name", "Becle")); param.Add(new APIParameter("action_name", "访问我们")); param.Add(new APIParameter("action_link", "http://dev.renren.com")); param.Add(new APIParameter("description", shareContent)); param.Add(new APIParameter("caption", "")); param.Add(new APIParameter("image", "http://www.aaronke.co.cc/ic/img/home/facebook_logo.jpg")); api.WidgetDialog(this, WidgetDialogType.FeedDialog, param, WidgetDialogComplete); }
/// <summary> /// /// Application 对象的构造函数。 /// </summary> public App() { // 未捕获的异常的全局处理程序。 UnhandledException += Application_UnhandledException; // 标准 Silverlight 初始化 InitializeComponent(); // 特定于电话的初始化 InitializePhoneApplication(); // 调试时显示图形分析信息。 if (System.Diagnostics.Debugger.IsAttached) { // 显示当前帧速率计数器。 Application.Current.Host.Settings.EnableFrameRateCounter = true; // 显示在每个帧中重绘的应用程序区域。 //Application.Current.Host.Settings.EnableRedrawRegions = true; // 启用非生产分析可视化模式, // 该模式显示递交给 GPU 的包含彩色重叠区的页面区域。 //Application.Current.Host.Settings.EnableCacheVisualization = true; // 通过将应用程序的 PhoneApplicationService 对象的 UserIdleDetectionMode 属性 // 设置为 Disabled 来禁用应用程序空闲检测。 // 注意: 仅在调试模式下使用此设置。禁用用户空闲检测的应用程序在用户不使用电话时将继续运行 // 并且消耗电池电量。 PhoneApplicationService.Current.UserIdleDetectionMode = IdleDetectionMode.Disabled; } api = new RenrenAPI("215066", "4b5eba6894994db497f2ec719449c481", "5572c351fae44df5bcfaf0770ae5a5cd"); api.Cleanlog(); for (int i = 0; i < 5; i++) { SavingImage[i] = new BitmapImage(); } }