admin管理员组

文章数量:1410697

In my website, I am using a Java Applet. The mouse pointer changes to busy whenever I click a link in the JApplet. I want to check if mouse pointer is idle or busy. I have tried to import win32gui as explained in this answer in vain. Is it feasible to check if mouse is idle or busy in sikulix 2.0.5?

This is what I'm trying to achieve

while mouse_pointer_is_idle:
    click("1733637249299.png")
    mouseMove(1,0)
    update_if_mouse_pointer_is_idle_or_not()
    wait(0.3)

Thanks in advance

In my website, I am using a Java Applet. The mouse pointer changes to busy whenever I click a link in the JApplet. I want to check if mouse pointer is idle or busy. I have tried to import win32gui as explained in this answer in vain. Is it feasible to check if mouse is idle or busy in sikulix 2.0.5?

This is what I'm trying to achieve

while mouse_pointer_is_idle:
    click("1733637249299.png")
    mouseMove(1,0)
    update_if_mouse_pointer_is_idle_or_not()
    wait(0.3)

Thanks in advance

Share Improve this question edited Mar 8 at 11:40 Basheer Jarrah 6344 silver badges16 bronze badges asked Mar 8 at 8:11 user3103982user3103982 11110 bronze badges
Add a comment  | 

1 Answer 1

Reset to default 0

Hi I solved it using MANIFEST.MF flie to add jna dependencies (compulsary empty newline at last line else it won't build dependencies)
Manifest-Version: 1.0
Main-Class: newmain
Class-Path: lib/jna.jar lib/jna-platform.jar

I downloaded JAVA JDK 1.8 to make it work in sikuli
Then I did

E:\\jdk1_8_0_202\\bin\\jar cfm Jar.jar MANIFEST.MF \*.class

then in sikuli

sys.path.append("E:\\Downloads\\jarf\\withdependency\\newmain.jar")  
import newmain;  
ct=newmain.cursor_type();  
print(ct.getCode());  
print(ct.getCode()==32514);

https://drive.google/file/d/1w18kSUs0HlL6i2OqQ6rv2qHww6az1I6Y/view

This is my jar file

Thanks

本文标签: statesikulix 205 detect if mouse pointer is idle or busyStack Overflow