• iOS 实现从后台切换到前台-复制分享宝贝内容,打开淘宝APP,自动弹出宝贝提示信息


    - (void)applicationDidBecomeActive:(UIApplication *)application {
    
        
    
        NSLog(@"
     ===> 程序重新激活 !");
    
     
    
        
    
        NSString *str = [YIdentificationClipboard getIdentificationData];
    
        NSLog(@"strr:%ld",(long)str.length);
    
        if (str.length >= 2) {
    
            //弹窗
    
            //智能搜索 提示弹窗
    
            IdentificationClipboardView *idview = [IdentificationClipboardView initIdentificationClipboardView];
    
           idview.contentstrings = str;
    
           idview.getsearchblock = ^(NSString *searchstr) {
    
                NSLog(@"searchstrsearchstr:%@",searchstr);
    
                //跳转到搜索页面
    
                UITabBarController *tabar = (UITabBarController *)self.window.rootViewController;
    
                MainSeachJumpQueryVc *searchjumpvc = [[MainSeachJumpQueryVc alloc]init];
    
                searchjumpvc.titlename = str;
    
                UINavigationController *nav = tabar.viewControllers[tabar.selectedIndex];
    
                searchjumpvc.hidesBottomBarWhenPushed = YES;
    
                [nav pushViewController:searchjumpvc animated:YES];
    
            };
    
        }
    
     
    
    }
    

      

     

  • 相关阅读:
    将软件做成服务,并开机自启
    ubuntu下sublime Text3配置C++编译环境
    StratifiedKFold与GridSearchCV版本前后使用方法
    o2o优惠券使用预测
    Meshgrid函数的基本用法(转载)
    Andrew Ng机器学习课程,第一周作业,python版本
    多元高斯分布(转载)
    Tensorflow图像处理
    TensorFlow最佳实践样例
    个人资源索引
  • 原文地址:https://www.cnblogs.com/shenlaiyaoshi/p/8759459.html
Copyright © 2020-2023  润新知