Ignore:
Timestamp:
10/02/19 14:19:48 (5 years ago)
Author:
bln4
Message:

Implementation of ProfileManager. Refactor + additional content for how new profiles are created. The refactoring split out the creation of the default profile from user profiles. Refactoring revealed a long term bug that was causing user profiles to generate with incorrect information. The additional content fixed this bug by introducing the ${USER.NAME} variable, so that the default profile frameset can specify resource locations located in the users resource directory.

org.expeditee.auth.AuthenticatorBrowser
org.expeditee.auth.account.Create
org.expeditee.gui.Browser
org.expeditee.gui.management.ProfileManager
org.expeditee.setting.DirectoryListSetting
org.expeditee.setting.ListSetting
org.expeditee.settings.UserSettings

Implementation of ResourceManager as a core location to get resources from the file system. Also the additional variable ${CURRENT_FRAMESET} to represent the current frameset, so that images can be stored in the directory of the current frameset. This increases portability of framesets.

org.expeditee.gui.FrameIO
org.expeditee.gui.management.ResourceManager
org.expeditee.gui.management.ResourceUtil
Audio:

#NB: Audio used to only operate on a single directory. This has been updated to work in a same way as images. That is: when you ask for a specific resouce, it looks to the user settings to find a sequence of directories to look at in order until it manages to find the desired resource.


There is still need however for a single(ish) source of truth for the .banks and .mastermix file. Therefore these files are now always located in resource-<username>\audio.
org.apollo.agents.MelodySearch
org.apollo.audio.structure.AudioStructureModel
org.apollo.audio.util.MultiTrackPlaybackController
org.apollo.audio.util.SoundDesk
org.apollo.gui.FrameLayoutDaemon
org.apollo.io.AudioPathManager
org.apollo.util.AudioPurger
org.apollo.widgets.FramePlayer
org.apollo.widgets.SampledTrack

Images:

org.expeditee.items.ItemUtils

Frames:

org.expeditee.gui.FrameIO

Fixed a error in the FramePlayer class caused by an incorrect use of toArray().

org.apollo.widgets.FramePlayer


Added several short cut keys to allow for the Play/Pause (Ctrl + P), mute (Ctrl + M) and volume up/down (Ctrl + +/-) when hovering over SampledTrack widgets.

org.apollo.widgets.SampledTrack


Changed the way that Authenticate.login parses the new users profile to be more consistance with other similar places in code.

org.expeditee.auth.account.Authenticate


Encapsulated _body, _surrogateItemsBody and _primaryItemsBody in Frame class. Also changed getBody function to take a boolean flag as to if it should respect the current surrogate mode. If it should then it makes sure that labels have not changed since last time getBody was called.

org.expeditee.gui.Frame

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/expeditee/gui/Browser.java

    r1415 r1434  
    269269                Text.InitFonts();
    270270
    271                 Settings.Init();
    272                 Frame userProfile = loadProfiles();
    273 
    274271                if (!AuthenticatorBrowser.isAuthenticationRequired() && UserSettings.PublicAndPrivateResources) {
    275                         String userName = UserSettings.ProfileName.get();
     272                        String userName = System.getProperty("user.name"); //UserSettings.ProfileName.get();
    276273                        if (!FrameIO.personalResourcesExist(userName)) {
    277274                                FrameIO.setupPersonalResources(userName);
    278275                        }
    279276                }
     277               
     278                Settings.Init();
     279                Frame userProfile = loadInitialProfiles();
     280                FrameIO.changeParentAndSubFolders(FrameIO.PARENT_FOLDER);
     281               
    280282                // Listen for save status to display during and after runtime
    281283                EntitySaveManager.getInstance().addSaveStateChangedEventListener(this);
     
    285287                       
    286288                        // Go to the start frame if specified, otherwise go to the profile frame
    287                         Frame start = null;
    288289                        if (getStartFrame() == null) {
    289290                                setStartFrame(UserSettings.StartFrame.get());
     
    293294                        }
    294295
     296                        Frame start = null;
    295297                        if ((start = FrameIO.LoadFrame(getStartFrame())) != null) {
    296298                                // Make sure HomeFrame gets set
     
    527529         * @return The user's profile frame.
    528530         */
    529         public static Frame loadProfiles()
     531        public static Frame loadInitialProfiles()
    530532        {
    531533                String defaultProfileName = UserSettings.DEFAULT_PROFILE_NAME;
    532                 String userName = UserSettings.ProfileName.get();
    533 
     534                String userName = System.getProperty("user.name");
     535
     536                Frame defaultProfile = loadProfile(defaultProfileName);
    534537                Frame userProfile = loadProfile(userName);
    535                 Frame defaultProfile = loadProfile(defaultProfileName);
    536538               
    537539                MessageBay.warningMessages(FrameUtils.ParseProfile(defaultProfile));
     
    544546                }
    545547               
    546                 MessageBay.warningMessages(FrameUtils.ParseProfile(userProfile));
     548                //MessageBay.warningMessages(FrameUtils.ParseProfile(userProfile));
    547549               
    548550                if (cursor != null && !FreeItems.hasCursor()) {
    549551                        FreeItems.setCursor(cursor);
    550552                }
     553               
     554                FrameUtils.ParseProfile(userProfile);
    551555               
    552556                return userProfile;
Note: See TracChangeset for help on using the changeset viewer.