Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 9 additions & 7 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -6,23 +6,24 @@ repositories {
mavenLocal()
maven {
url = 'https://repo.runelite.net'
content {
includeGroupByRegex("net\\.runelite.*")
}
}
mavenCentral()
}

def runeLiteVersion = '1.8.30'
def runeLiteVersion = 'latest.release'

dependencies {
compileOnly group: 'net.runelite', name:'client', version: runeLiteVersion

compileOnly 'org.projectlombok:lombok:1.18.4'
annotationProcessor 'org.projectlombok:lombok:1.18.4'
compileOnly 'org.projectlombok:lombok:1.18.30'
annotationProcessor 'org.projectlombok:lombok:1.18.30'

testImplementation 'junit:junit:4.12'
testImplementation 'org.slf4j:slf4j-simple:1.7.12'
testImplementation group: 'net.runelite', name:'client', version: runeLiteVersion, {
exclude group: 'ch.qos.logback', module: 'logback-classic'
}
testImplementation group: 'net.runelite', name:'client', version: runeLiteVersion
testImplementation group: 'net.runelite', name:'jshell', version: runeLiteVersion
}

group = 'io.hydrox.contextualcursor'
Expand All @@ -31,4 +32,5 @@ sourceCompatibility = '1.8'

tasks.withType(JavaCompile) {
options.encoding = 'UTF-8'
options.release.set(11)
}
Original file line number Diff line number Diff line change
Expand Up @@ -103,20 +103,10 @@ private void storeOriginalCursor()
{
return;
}
try
{
// All this because clientUI doesn't have a `getCursor` function.
Field f = clientUI.getClass().getDeclaredField("container");
f.setAccessible(true);
JPanel container = (JPanel) f.get(clientUI);
final Cursor currentCursor = container.getCursor();
if (!currentCursor.getName().equals("blank"))
{
originalCursor = container.getCursor();
}
}
catch (NoSuchFieldException | IllegalAccessException ignored)
final Cursor currentCursor = clientUI.getCurrentCursor();
if (!currentCursor.getName().equals("blank"))
{
originalCursor = clientUI.getCurrentCursor();
}
}

Expand Down