Can now add a '--debug' or a
'--trace' option to the DisplayMagician
to force it to generate a TRACE log for that
session only. Once you close the application
it will go back to the normal logging level
set within the Settings Window.
Managed to break some logic when trying to
add robustness.... effectively doing the
opposite of what I was trying to do :/. Now
*should* be fixed, but we shall see with more
testing.
This code now will cope with incorrectly
formatted icons, and will simply ignore
them and move on to the next one.
This also fixes a game ILV adaptor error
which was causing argumentnullexceptions
Changed to use a single bitmap generator
to try and simplify and standardise the way
that images are extracted from the games.
Have tried to use every method to extract
icons from icon files and from exes, but it's
still not quite right :(
Currently struggling with the fact that
the smaller game icons don't get extracted
properly, and that they end up tucked into
the top left of the 256x256 bitmap at
32x32 size... so really tiny. Need to find a
fix for this so it always returns a 256x256,
and attempts to grow the 32x32 icons into
256x256 icons.
This is almost working. I'm struggling with
the icons loaded from various icon files which
are coming in really small rather than the large
size they should be. The .Net Icon constructor
isn't making an Icon the size I requested, so I may
need to change something else.
Can now create new start programs. Still
isn't saving and loading the start programs
into the shortcuts properly, and still loads
empty start programs which we need to
filter out.
Lots of improvements to make still
but the basic UI is working as it should.
Big thanks to @teawithcookies for the
tip to set DragDropEffects to Move in
order to make DragDrop method fire!
That took me 20 mins to figure out...
Drag and drop finally works! But there is
no feedback, and no animation and no
cursor control. And the page still doesn't
actually save the information, and it can't
have new start programs added to it yet.
It's fair to say there is still a lot to do :/
The panel successfully has the usercontrols
put into it, but it doesn't reorganise the rest
of the usercontrols when one is deleted up
to head of the list. I've done some research
and the internet tells me to move from a panel
container to a FlowLayoutPanel or a
TableLayoutPanel to get the automatic redrawing
functionality. It's apparently far easier to swap
than to write the redrawing code yourself.
So thats the plan for later this week.
First attempt at using a customer User
Control to make it easier to create dynamic
list of start programs to kick off before the
main program is started.
I already have the ability within the data model
to store and track multiple start programs... the
difficulty is in making the WninForms UI handle
a dynamic number of start programs. This is the
basic construction of it, but it needs a LOT of UI
work.
Managed to add the Hotkey list
that shows the user the entire list
of hotkeys across the application.
Also allows you to delete them all!
This function is now complete, and
is all working based on my testing.
Yay! Managed to get all the hotkey
logic working so all types of hotkeys
work fine. Next step is getting the
list of dynamic hotkeys populated
from the Display Profiles and the
Game Shortcuts, and then hooking up
the Clear All Hotkeys button so that it
clears the dynamic hotkeys too!
In this first working hotkey scenario
the DisplayProfiles and Shortcuts can
be run from Hotkey. I now need to add
the ability to run the mainfor, display profile
config page, and the shortcut library itself.
And of course add the items to the settings
window so they can be changed.
This iwas a stupid mistake. I forgot to change
the Uplay library references when I copied them
to nmake the OriginLibrary. This caused issues
as they cross pollinated, breaking both :(.
OriginLibrary wasn't added to the validity
checking, so no Origin games would work.
Also added a LOAD more trace logging with the
Origin library so I can see from the logs what's
happening. Also updated the version to 1.0.5.1.
And finally, removed unneeded validityrefresh
from the base ShortcutItem constructor as it
is refreshed later anyway. Should speed up
object creation a little.
Managed to get the hotkeys for
the DisplayProfiles and the Game
Shortccuts to work ok. Still needs
polish for the HotKeyForm, and I
need a way to set the MainWindow,
DisplayProfileWindow and
ShortcutWindow Hotkeys
Completed the Shortcut and Display Profile
hotkey UI interface to a satisfactory level.
The hotkey settings are stored with the
profile JSON for profiles, and with the
shortcut JSON for shortcuts. This means
they load correctly and are remembered
between runs of DisplayMagician.
Next step is to actually register the Hotkeys
so they work, and then allow them to be
replaced or removed when they are changed.
At this point, we now have a hotkey form
that can generate hotkeys, and we have a way
of passing it some text to make it obvious which
hotkey we are setting. Additonally we can get
the set hotkey back.
Next steps are to store the hotkeys with the
display profiles and the game shortcuts, and
to load them as we load the files in.
This form will show when the user wants
to set a hotkey for a display profile or for
a shortcut. This will not be used for the
setting the main window, or shortcut library
hotkey...those will be set in the settings
window.