zoukankan      html  css  js  c++  java
  • atitit.激活一个窗口总结 swing java .net php

    atitit.激活一个窗口总结

    1     激活窗口:鼠标激活vswindows消息激活... 1

    1.1      Web框架激活... 1

    2     退出激活窗口热键(dbg模式)... 1

    3     俩个窗口激活优先级... 2

    4     Web控件激活—code. 3

    1       激活窗口:鼠标激活vs windows消息激活

    原则上尽可能的使用消息激活。。

    WinGet, active_id2, ID, ahk_classSunAwtFrame

                  ;MsgBox%active_id2%

    WinActivate,  ahk_class SunAwtFrame

    1.1   Web框架激活

    使用消息不能激活 。。ControlFocus,InternetExplorer_Server

                  ControlFocus,InternetExplorer_Server1

    只好使用鼠标激活。。(鼠标左右键均不适合激活用,中建激活最好了。。。

    final Robot rb = new Robot();

     clickMidKeyMouse(rb,50);

     

    作者:: 老哇的爪子 Attilax 艾龙,  EMAIL:1466519819@qq.com

    转载请注明来源: http://blog.csdn.net/attilax

     

    2      退出激活窗口热键(dbg模式)

     

    #c:: ExitApp    ::win+c

    要放的个loop 后面了。。被而不个cant exe

     

    3      俩个窗口激活优先级

    DetectHiddenWindows, On

    Loop

    {

    ;class PowerDVD14

           ;PowerDVD

           ;ahk_classPowerDVD14

           WinGet,active_id, ID, PowerDVD,,Everything,Everything

           WinActivate,ahk_classPowerDVD14

           WinMaximize,ahk_classPowerDVD14

           ;;,,Everything,Everything

    ;MsgBox aa

            IfWinNotExist,ahk_class PowerDVD14

            {

                  WinGet,active_id2, ID, ahk_class SunAwtFrame

                  ;MsgBox%active_id2%

                  WinActivate,  ahk_class SunAwtFrame

                  ControlFocus,InternetExplorer_Server

                  ControlFocus,InternetExplorer_Server1

           }

    ;msgbox tt

    Sleep, 3000

    }

    #c:: ExitApp

    4       Web控件激活—code

       publicstaticvoid activeWin() throws AWTException {

          while(true)

          {

             try {

                booleanexistPower=false;

                try {

                    String playserver=PropX.getConfig(pathx.classPath()+"/cfg.properties", "actsleep");

                    intactsleep=3000;

                    try {

                       actsleep=Integer.parseInt(playserver);

                    } catch (Exception e) {

                       // TODO: handle exception

                    }

                start: Thread.sleep(actsleep);

                } catch (InterruptedException e) {

                    // TODO Auto-generated catch block

                    e.printStackTrace();

                }

                List<String> set=ProcessX.  getProcessList();

             // List<String>lst=

                for (String line : set) {

                    if(line.contains("PowerDVD.exe") || line.contains("PowerDVDMovie"))

                    {

                    System.out.println("exist dvd ");

                    existPower=true;

                       break ;

                    }

                }

                if(existPower)   // if sexist power dvd ,,b actselect win..

                    continue;

                System.out.println("---no exist dvd");

                 final Robot rb = new Robot();

     

                 clickMidKeyMouse(rb,50);

             } catch (Exception e) {

                e.printStackTrace();

             }

            

         

          }

       }

     

    参考

    projatibrow

    actPlayWin.ahk

  • 相关阅读:
    RuntimeError: Object: Could not open SDE workspace
    数字证书原理
    ie浏览器总跳转到 http://hao.360.cn
    ArcCatalog连接ArcSDE连接报:unable to create new database connection file,permission is denied
    卸载重装ArcGIS Enterprise 注意事项
    修改机器名、IP对arcgis server、portal的影响?
    arcpy调试
    jquery的show/hide/toggle详解
    jquery的回调对象Callbacks详解
    元素全屏居中(不变形)
  • 原文地址:https://www.cnblogs.com/attilax/p/15198941.html
Copyright © 2011-2022 走看看