Migrate to buildable gradle project

* add gradle wrapper
* move source files to gradle project layout
* use SetWindowLongPtr instead of SetWindowLong
* add static library files for Gdi32
* migrate to use jlibloader 0.2
* move auxiliary files to project root
* remove obsolete files
This commit is contained in:
2014-11-26 22:27:44 +00:00
parent f986dd58c5
commit 31050c8893
44 changed files with 1135 additions and 1495 deletions

131
site/fml/faq.fml Normal file
View File

@@ -0,0 +1,131 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<faqs title="Frequently Asked Questions">
<part id="general">
<title>General</title>
<faq id="what-is-jintellitype">
<question>
What is <strong>JIntellitype</strong>?
</question>
<answer>
<strong>JIntellitype</strong> is a Java API for Windows that allows you to
register global hotkeys and listen for Microsft Intellitype commands.
</answer>
</faq>
<faq id="on-which-platform">
<question>
On which platform does it run?
</question>
<answer>
Since <strong>JIntellitype</strong> uses Windows specific calls it will
only work on Windows. Windows 2000 or higher recommended. For a Linux
version see <a href="http://sourceforge.net/projects/jxgrabkey/">JxGrabKey</a> project on Sourceforge.
</answer>
</faq>
<faq id="x64-jdk">
<question>
Does it run on x64 JDK or JRE's?
</question>
<answer>
Starting with 1.3.3 JINtellitype comes with a 64 bit DLL. To use it Simply rename the DLL to
JIntellitype.dll or use the Jintellitype.setLibraryLocation(''); function to set the path to JIntellitype64.dll.
</answer>
</faq>
<faq id="where-get-help">
<question>
Where do I get help on <strong>JIntellitype</strong>?
</question>
<answer>
This FAQ answers some frequent questions already, please read the
it thoroughly.
<p></p>
If these resources don't help you with your problem,
or if you think that you found a bug that is not yet documented,
you should <a href="contacts.html">contact</a> us.
</answer>
</faq>
<faq id="question-not-addressed">
<question>
I have a question that is not addressed here.
Where can I ask?
</question>
<answer>
See our <a href="contacts.html">Contacts</a> page.
</answer>
</faq>
</part>
<part id="problems">
<title>Problems</title>
<faq id="not-getting-intellitype-messages">
<question>
I am pressing my special Intellitype keys on my keyboard but nothing is happening?
</question>
<answer>
First, make sure you have followed instructions for using JIntellitype properly. Next,
make sure you do not have Microsft Intellitype drivers installed. The Microsoft software
intercepts the messages before they get to JIntellitype and "eats" them. You can tell if
you are running Microsoft Keyboard software by opening Task Manager and looking for the
process name "itype.exe".
</answer>
</faq>
<faq id="two-instances">
<question>
I am using Jintellitype.checkInstanceAlreadyRunning("MyApp") but it is allowing me to open
my application more than once when I am expecting it not to?
</question>
<answer>
Make sure that "MyApp" is the getTitle() of the main JFrame of your application.
JIntellitype checks by Window title name.
</answer>
</faq>
</part>
<part id="development">
<title>Development</title>
<faq id="can-i-contribute">
<question>
Can I contribute?
</question>
<answer>
Yes, please! Check out the <a href="contacts.html">contact</a> page and contact us!
</answer>
</faq>
<faq id="i-found-a-bug">
<question>
I think I found a bug in <strong>JIntellitype</strong>.
What should I do?
</question>
<answer>
You should post it to the <a href="http://forum.melloware.com/index.php">forums</a> to
make sure it is documented.
</answer>
</faq>
<faq id="when-will-feature">
<question>
When will feature XYZ be implemented?
</question>
<answer>
Depends. If it is something you really sorely need, you could (politely)
try to exert some pressure on us. You can also try to pay us.
Or try to implement your feature yourself and send us some patches.
In any case, you should <a href="contacts.html">contact</a> us about your problem.
</answer>
</faq>
</part>
</faqs>

View File

@@ -0,0 +1 @@
<% Response.Redirect("http://melloware.com/products/jintellitype/index.html");%>

BIN
site/resources/favicon.ico Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 766 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

56
site/site.xml Normal file
View File

@@ -0,0 +1,56 @@
<?xml version="1.0" encoding="UTF-8"?>
<project name="${project.name}">
<bannerLeft>
<src>http://melloware.com/images/header.jpg</src>
<href>http://melloware.com/</href>
</bannerLeft>
<bannerRight>
<src>./images/jintellitype-banner.png</src>
<href>http://melloware.com/products/jintellitype/</href>
</bannerRight>
<skin>
<groupId>com.melloware</groupId>
<artifactId>melloware-skin</artifactId>
<version>1.0</version>
</skin>
<publishDate format="dd MMM yyyy" />
<poweredBy>
<logo name="Paypal Donation" href="https://www.paypal.com/cgi-bin/webscr?cmd=_xclick&amp;business=info%40melloware%2ecom&amp;item_name=JIntellitype%20Donation&amp;item_number=5&amp;no_shipping=0&amp;no_note=1&amp;tax=0&amp;currency_code=USD&amp;bn=PP%2dDonationsBF&amp;charset=UTF%2d8" img="./images/paypal.gif"/>
<logo name="Built with Maven 2" href="http://maven.apache.org" img="http://maven.apache.org/images/logos/maven-feather.png"/>
</poweredBy>
<body>
<links>
<item href="http://www.melloware.com/" name="Melloware"/>
<item href="http://forum.melloware.com/index.php" name="Forums"/>
</links>
<head>
<meta name="keywords" content="Intellitype, Melloware, JIntellitype, Intelliremote, Java, Jukebox, cross, platform, Java Intellitype, RegisterHotKey, UnregisterHotKey, global, Hotkey"/>
<link rel="icon" href="http://www.melloware.com/products/jintellitype/favicon.ico"/>
<link rel="shortcut icon" href="http://www.melloware.com/products/jintellitype/favicon.ico"/>
</head>
<menu name="${project.name}">
<item name="Introduction" href="/index.html" />
<item name="Quick Start" href="/quick-start.html" />
<item name="Compiling DLL" href="/dev-cpp.html" />
<item name="Release Notes" href="/changes-report.html" />
<item name="FAQ" href="/faq.html" />
<item name="Download" href="http://melloware.com/download/" />
</menu>
<menu name="Support">
<item name="Contact Us" href="/contacts.html" />
<item name="Forums" href="http://forum.melloware.com/index.php" />
<item name="Donate" href="https://www.paypal.com/cgi-bin/webscr?cmd=_xclick&amp;business=info%40melloware%2ecom&amp;item_name=JIntellitype%20Donation&amp;item_number=5&amp;no_shipping=0&amp;no_note=1&amp;tax=0&amp;currency_code=USD&amp;bn=PP%2dDonationsBF&amp;charset=UTF%2d8" />
</menu>
<menu name="Documentation" ref="reports"/>
</body>
</project>

32
site/xdoc/contacts.xml Normal file
View File

@@ -0,0 +1,32 @@
<?xml version="1.0"?>
<document>
<properties>
<title>Contacts</title>
<author email="info.AT.melloware.DOT.com">Emil A Lefkof III</author>
</properties>
<body>
<section name="Contacts">
<p>
The preferred way of getting in touch with one of the developers of
<strong>JIntellitype</strong> is via the <a href="http://forum.melloware.com/index.php">forums</a>.
Please direct any matters of general user support, questions, suggestions, discussions, etc.,
to the <a href="http://forum.melloware.com/index.php">forums</a>.
</p>
<subsection name="Developers and Contributors">
<p>
In special cases, you may try to contact directly one of the
<a href="team-list.html">developers or contributors</a>. You
can always send request to info@melloware.com also.
</p>
</subsection>
</section>
</body>
</document>

37
site/xdoc/dev-cpp.xml Normal file
View File

@@ -0,0 +1,37 @@
<document>
<properties>
<title>JIntellitype</title>
<author email="info.AT.melloware.DOT.com">Emil A Lefkof III</author>
</properties>
<body>
<section name="Compiling Dev C++ DLL">
<p>
Jintellitype uses the <a href="http://www.bloodshed.net/dev/devcpp.html">Bloodshed Dev C++ IDE</a> for compiling the JIntellitype.dll.
</p>
<p>
1. Once you have DevC++ installed, just open the JIntellitype.dev project file.
</p>
<p>
2. Navigate to the menu option <strong>Project->Options</strong>.
</p>
<p>
3. Make sure to set the entries in the screenshot below to your JDK location.
<br/>
<img alt="Project Options" src="./images/devc-jni.jpg"/>
</p>
<p>
4. Change your <strong>Project->Options Build Options</strong> to point to an output directory of your choosing.
</p>
<p>
5. Use the menu or toolbar button to build the DLL!
</p>
</section>
</body>
</document>

136
site/xdoc/index.xml Normal file
View File

@@ -0,0 +1,136 @@
<document>
<properties>
<title>Java API for Microsoft Intellitype</title>
<author email="info.AT.melloware.DOT.com">Emil A Lefkof III</author>
</properties>
<body>
<section name="JIntellitype API">
<subsection name="Introduction">
<p>
JIntellitype is a Java API for interacting with Microsoft Intellitype
commands as well as registering for Global Hotkeys in your Java application.
The API is a Java JNI library that uses a C++ DLL to do all the communication
with Windows. <strong>NOTE:</strong> This library ONLY works on Windows. If
you are looking for a Linux version please see <a href="http://sourceforge.net/projects/jxgrabkey/">JxGrabKey</a> project on Sourceforge.
</p>
</subsection>
<subsection name="Hotkeys">
<p>
Have you ever wanted to have CTRL+SHIFT+G maximize your Swing application
on the desktop? Even if that application did not have focus? Well, now you can! By
registering a Windows Hotkey combination, your application will be alerted
when the combination you select is pressed anywhere in Windows. Windows has the
API call <a href="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winui/winui/windowsuserinterface/userinput/keyboardinput/keyboardinputreference/keyboardinputfunctions/registerhotkey.asp">RegisterHotKey</a>
for registering a global hotkey combination so that your app receives that message
no matter what else you are doing or even if your application has focus. This is
a commonly requested feature in Java that has now been implemented by JIntellitype.
Check out the <a href="quick-start.html">Quick Start Guide</a> for an example on how to use JIntellitype.
</p>
</subsection>
<subsection name="Intellitype">
<p>
Have you ever wanted your Java application to react to those special Play, Pause,
Stop keys on some newer keyboards like Winamp and Windows Media Player do? Ever wonder how they do it?
If you want your application to "listen" for those special keys, now you can with JIntellitype!
Just register an IntellitypeListener and you will be notified when those messages are received.
To read more about these special commands see the <a href="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/winui/winui/windowsuserinterface/userinput/keyboardinput/keyboardinputreference/keyboardinputmessages/wm_appcommand.asp">MSDN Documentation</a>
about the Intellitype commands.
Check out the <a href="quick-start.html">Quick Start Guide</a> for an example on how to use JIntellitype.
</p>
</subsection>
<subsection name="Donate">
<p>
Although JIntellitype is open source, small financial donations are appreciated. By supporting Melloware, you help fund the development
(mainly development tools and internet access etc) of Melloware's Software. To send money, simply click on the PayPal icon to the left.
</p>
</subsection>
<subsection name="Applications Using JIntellitype">
<p>
<a href="http://melloware.com/products/jukes/index.html">Jukes</a> cross platform music player and organizer.
</p>
<p>
<a href="http://jajuk.sourceforge.net">JaJuk</a> cross platform swiss army knife music player including DJ mode and much more!
</p>
<p>
<a href="http://www.c2tn.de">C2TN</a> C2TN is the first RSS Reader which integrates completely into your desktop.
</p>
<p>
<a href="http://www.atunes.org/">aTunes</a> aTunes is a GPL audio player and manager.
</p>
<p>
<a href="http://www.topkeys.net">Topkeys</a> emulates the mouse using the keyboard.
</p>
<p>
<a href="http://code.google.com/p/google-translate-desktop/">Google Translate Desktop</a> is a free unofficial Java desktop client based on Google Translate service.
</p>
<p>
<a href="http://kolovos.wiki.sourceforge.net/MiniGen">MiniGen</a> is a program that can generate text in any Windows-based (tested on XP/Vista) application based on the currently selected text in a non-invasive manner.
</p>
<p>
<a href="http://xtrememp.sourceforge.net/">Xtreme Media Player</a> is a free cross-platform media player.
</p>
<p>
<a href="http://github.com/marnix/mytime/tree/master">MyTime</a> is a simple time tracker, mostly controlled through the tray icon.
</p>
<p>
<a href="http://radis.sourceforge.net/">RadiS</a> is a cool-looking mouse menu that opens upon a global hot-key. Allows sub-menus which will be displayed in an adjacent partly circle.
</p>
<p>
<a href="http://jshot.info/">JShot</a> is a free and multiplatform screen capture and uploader utility which allows you to capture a part of your screen and publish it in one step.
</p>
<p>
<a href="http://sourceforge.net/projects/opensoundboard">OpenSoundboard</a> plays sound files (.wav, .mp3) when the user presses hotkeys.
</p>
<p>
<a href="http://clipcomrade.sourceforge.net/">Clipcomrade</a> - simple and free open source windows clipboard manager tool
</p>
<p>
<a href="http://wordoholic.com/">Wordoholic Learner</a> - a cross-platform language learning tool
</p>
<p>
<a href="http://code.google.com/p/hotshots/">Hotshots</a> - Easy to use screenshot utility for Windows and Linux
</p>
<p>
<a href="http://code.google.com/p/g15lastfm/">G15Lastfm</a> - Last.fm player for G15 gaming keyboard
</p>
<p>
<a href="http://code.google.com/p/webapp-workplace/">webapp-workplace</a> - Web Workspace/Client to provide notifications for different web applications such as gmail, facebook, etc.
</p>
<p>
<a href="http://code.google.com/p/hawkscope/">Hawkscope</a> - is a productivity tool that allows you to access your hard drive contents quickly via system tray / menubar icon with dynamic pop-up menu.
</p>
</subsection>
<subsection name="Features">
<ul>
<li>Can register global hotkey combinations in Java applications in Windows </li>
<li>Application is notified even if it does not have focus.</li>
<li>Can react to those Play, Pause, Stop, Next, Forward Media keys like Winamp</li>
<li>Very little code, easy to use API</li>
<li>Examples included in <a href="xref-test/com/melloware/JIntellitypeTester.html">JIntellitypeTester.java</a></li>
</ul>
</subsection>
</section>
<script src="http://www.google-analytics.com/urchin.js" type="text/javascript">
</script>
<script type="text/javascript">
_uacct = "UA-2908999-2";
urchinTracker();
</script>
</body>
</document>

110
site/xdoc/quick-start.xml Normal file
View File

@@ -0,0 +1,110 @@
<document>
<properties>
<title>JIntellitype</title>
<author email="info.AT.melloware.DOT.com">Emil A Lefkof III</author>
</properties>
<body>
<section name="Quick Start Guide">
<p>
Here is a simple quick start for getting up and running with JIntellitype quickly.
An <a href="xref-test/com/melloware/JIntellitypeTester.html">Example</a> is also included in the
distribution to show you how easy it is to use JIntellitype.
</p>
<subsection name="Eclipse">
<p>
If you are familiar with Eclipse there is a full working example Eclipse project that can be
found here <a href="http://melloware.com/download/jintellitype/jintellitype-example.zip">Eclipse Example</a>.
In Eclipse just navigate to <strong>File->Import->Existing Project Into Workspace</strong> and you are ready to go.
</p>
</subsection>
<subsection name="Instructions">
<p>
1. Make sure JIntellitype.dll is in your PATH or in \Windows\System32.
</p>
<p>
2. Initialize a <a href="apidocs/com/melloware/jintellitype/JIntellitype.html">JIntellitype</a> object.
<source>
// Initialize JIntellitype
...
JIntellitype.getInstance();
...
// OPTIONAL: check to see if an instance of this application is already
// running, use the name of the window title of this JFrame for checking
if (JIntellitype.checkInstanceAlreadyRunning("MyApp")) {
LOG.error("An instance of this application is already running");
System.exit(1);
}
</source>
</p>
<p>
3. To listen to hotkey's, you need to register the combinations to listen for.
<source>
// Assign global hotkeys to Windows+A and ALT+SHIFT+B
JIntellitype.getInstance().registerHotKey(1, JIntellitype.MOD_WIN, (int)'A');
JIntellitype.getInstance().registerHotKey(2, JIntellitype.MOD_ALT + JIntellitype.MOD_SHIFT, (int)'B');
//or you can use the Swing constants instead
JIntellitype.getInstance().registerSwingHotKey(3, Event.CTRL_MASK + Event.SHIFT_MASK, (int)'C');
// To unregister them just call unregisterHotKey with the unique identifier
JIntellitype.getInstance().unregisterHotKey(1);
JIntellitype.getInstance().unregisterHotKey(2);
JIntellitype.getInstance().unregisterHotKey(3);
</source>
</p>
<p>
4. Make sure to add a <a href="apidocs/com/melloware/jintellitype/HotkeyListener.html">HotKeyListener</a> and implement the interface.
<source>
//assign this class to be a HotKeyListener
JIntellitype.getInstance().addHotKeyListener(this);
// listen for hotkey
public void onHotKey(int aIdentifier) {
if (aIdentifier == 1)
System.out.println("WINDOWS+A hotkey pressed");
}
}
</source>
</p>
<p>
5. To use Intellitype commands implement the <a href="apidocs/com/melloware/jintellitype/IntellitypeListener.html">IntellitypeListener</a> interface.
<source>
//assign this class to be a IntellitypeListener
JIntellitype.getInstance().addIntellitypeListener(this);
// listen for intellitype play/pause command
public void onIntellitype(int aCommand) {
switch (aCommand) {
case JIntellitype.APPCOMMAND_MEDIA_PLAY_PAUSE:
System.out.println("Play/Pause message received " + Integer.toString(aCommand));
break;
default:
System.out.println("Undefined INTELLITYPE message caught " + Integer.toString(aCommand));
break;
}
}
</source>
</p>
<p>
6. Don't forget to call the cleanup method to release the DLL resources.
<source>
// Termination, make sure to call before exiting
...
JIntellitype.getInstance().cleanUp();
System.exit(0);
</source>
</p>
</subsection>
</section>
</body>
</document>