[advice] daily deeds polish

roippi

Developer
For fun I decided to teach myself a little Java swing in order to tackle daily deeds. A few people have suggested that some of the longer button clusters (showers, summons) could be collapsed into a combo box and an execute button.

ddupdate1.jpg

ddupdate2.jpg

That's where I am so far. To do: disable the summon options that are unavailable. That involves making a hashtable and learning how to implement and tweak a box renderer... so yeah that'll take me a bit.

Anyway, I'm looking for feedback. Should I make the boxes a uniform length, should I add a shower: or summon: label before the choices, should I collapse even more things into combo boxes, etc.
 
Last edited:
should I add a shower: or summon: label before the choices

If you mean as the first (non)option in the dropdown lists, then that seems like a good idea. The submit buttons next to them could then be shortened to say Go! or something like that.
 
Thanks for the feedback. Here's where I'm at now.

ddupdate3.jpg

Main thing I have to do now is add tooltip hints for everything. I don't think I'll be replacing any more buttons with combo boxes, unless somebody convinces me otherwise :cool:
 
Last edited:
That looks nice, but one comment: What lostcalpolydude was actually suggesting (and I agree with), is for there to be an option at the top of the list called "Summoning Chamber". When you first look at the Daily Deeds "Summoning Chamber" is selected. Clicking "GO" with "Summoning Chamber" selected does nothing, but it exists to label the drop-down.
 
Aaah. I knew I didn't quite get what he was saying.

That's easy enough to implement, and I agree that'd be a good change.
 
Kay.

ddupdate4.jpg or alternately,
ddupdate4 - nimbus.jpg

So that's about it, I think. I'd appreciate it if someone in a mac/*nix environment could try this out. I tried my best to make my implementation Look 'n Feel independent¹ but... never know.

¹Argh Nimbus. Why do you have to use your own naming conventions. Whyyyyy
 
Last edited:
Would it make sense to remove the extra "Summon:" on each line, since we already know they're summons?
 
Could do that, yeah. All of the shower options say "shower: " at the start as well.

Although once changed, the look of a combobox sitting there that just says "Moxie" or "Drinks" can be.. kinda ambiguous.
 
But since you can only do the summoning once daily. After it's been done, it doesn't matter for the rest of the day, so... Shower might make more sense to leave, since you can use it multiple times.
 
Oh, sorry. I'm not using any sort of VIP stuffs, so I don't know how usable the stuff is... if it's a one time use as well, then cut the "Shower:" as well.
 
Kay. Removed the labels.

I'll use this for a little while and see if I can break it before submitting a feature request.
 

Attachments

Last edited:
I'll test it on my Mac if someone can tell me how to not get "Hunk #X FAILED at Y." errors. The alternative seems to be manually merging (on a computer that I don't use much, even).
 
"Hunk #X FAILED at Y." errors.

Wow. Never heard that before.

On the off chance that it is related to applying the patch... NetBeans on Windows is very sensitive to the directory containing the patch file as compared to the directory that was the 'root' when the patch was created. Just looking at the patch file, I don't expect it to work for me unless the file patch file is placed in the directory that contains DailuDeedsPanel.java. That might be relavent or it might be totally useless.
 
That's funky. Probably caused by relative paths in the patch. Though.. I just tried applying the patch from my desktop in netbeans and couldn't reproduce.

Try opening up the patch in an editor and put src/net/sourceforge/kolmafia/swingui/panel/ before each DailyDeedsPanel.java and see if that works. Failing that, I can just spin another patch when I get home.

Edit: oooorrrr I could just access my home computer from a VPN at work and make the patch now. Man I'm a nerd :cool:

This patch has full paths from src/net/... , that should hopefully solve your patching problem.

Another thing I just noticed that could possibly use a combobox revamp: the skate buffs. To my chagrin, I've never set foot in the sea, so I don't know how they work, or even how the buttons look (I'm lazy, I could just enable them and see). Judging from the _vars, I'm guessing you get one of each buff once a day?
 
Last edited:
I'm going to just assume that patch from the OSX command line is useless, or alternatively that I broke it somehow. I applied the patch on my Windows machine using Tortoise, but then I got a compiler error for every instance of disabled_items.whatever(). I manually checked that all of the imports at the beginning were properly included into the merged file.

Paths had nothing to do with my issues because I put the patch file in the right folder for it to work anyway, and the updated version gave identical results.
 
I'm going to just assume that patch from the OSX command line is useless, or alternatively that I broke it somehow. I applied the patch on my Windows machine using Tortoise, but then I got a compiler error for every instance of disabled_items.whatever(). I manually checked that all of the imports at the beginning were properly included into the merged file.

Paths had nothing to do with my issues because I put the patch file in the right folder for it to work anyway, and the updated version gave identical results.

That.. sounds more serious than just patching issues.

disabled_items is a HashSet, and requires java.util.HashSet and java.util.Set. Did those get imported properly? If so, the only thing that I can think of is that I've done something that's not backwards-compatible with older versions of the JDK.

I'll email you a copy of DailyDeedsPanel.java so we can bypass this patching snafu and sort out what's going on.
 
Using the full modified file, I get the same compiler errors for both OSX 10.6 (this is a fresh repository just to test this one patch, should be the latest Java version) and Windows 7 (also the latest Java version).

The errors only mention java.util.Set, there's no mention of HashSet. Just for fun I also tried
Code:
import java.util.*;
and saw no change. If something couldn't be imported for whatever reason, there would be an error message letting me know that, right?
 
Back
Top