Changeset 1540
- Timestamp:
- 11/02/20 15:47:20 (4 years ago)
- Location:
- trunk
- Files:
-
- 12 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/null.banks
r1527 r1540 4 4 bnemhausPXOPCQ3.wav൝1.00 5 5 bnemhausFNSAEQ2.wav൝1.00 6 #$frameplayer#master$वbnemhausSNDGGN1.wav൝1.00 6 7 bnemhausDGRPEQ1.wav൝1.00 7 8 bnemhausKKWPJL7.wav൝1.00 … … 24 25 bnemhausBIKKPW1.wav൝1.00 25 26 bnemhausEXIBIN2.wav൝1.00 27 bnemhausRPIORU1.wav൝1.00 26 28 bnemhausGKCCXP2.wav൝1.00 27 29 bnemhausEXYLOP1.wav൝1.00 … … 43 45 bnemhausWVAWJO1.wav൝1.00 44 46 bnemhausHAQABB1.wav൝1.00 47 bnemhausSNDGGN1.wav൝1.00 45 48 bnemhausHSOCEV2.wav൝1.00 46 49 bnemhausTJNARP1.wav൝1.00 … … 53 56 bnemhausGQLOPS1.wav൝1.00 54 57 bnemhausUJHQEQ1.wav൝1.00 55 #$frameplayer#master$ 1.0058 #$frameplayer#master$0.130 56 59 bryceFYJNMX1.wav൝1.00 57 60 bnemhausNAMWRO3.wav൝1.00 -
trunk/src/org/expeditee/auth/Actions.java
r1506 r1540 48 48 import org.expeditee.encryption.CryptographyConstants; 49 49 import org.expeditee.gio.gesture.StandardGestureActions; 50 import org.expeditee.gui.Browser; 50 51 import org.expeditee.gui.DisplayController; 51 52 import org.expeditee.gui.Frame; … … 96 97 String backup = UserSettings.UserName.get(); 97 98 System.setProperty("user.name", userbackup); 99 Browser.setExpediteeUserName(userbackup); 98 100 UserSettings.UserName.set(userbackup); 99 101 userbackup = backup; -
trunk/src/org/expeditee/auth/AuthenticatorBrowser.java
r1504 r1540 84 84 public static boolean isAuthenticated() { 85 85 //return isAuthenticationRequired() && !UserSettings.UserName.get().equals(AuthenticatorBrowser.USER_NOBODY); 86 return isAuthenticationRequired() && ! System.getProperty("user.name").equals(AuthenticatorBrowser.USER_NOBODY);86 return isAuthenticationRequired() && !Browser.getExpediteeUserName().equals(AuthenticatorBrowser.USER_NOBODY); 87 87 } 88 88 -
trunk/src/org/expeditee/auth/account/Authenticate.java
r1504 r1540 53 53 } 54 54 55 System.setProperty("user.name",username);55 Browser.setExpediteeUserName(username); 56 56 UserSettings.UserName.set(username); 57 57 if (!username.equals(AuthenticatorBrowser.ADMINACCOUNT)) { -
trunk/src/org/expeditee/auth/account/Create.java
r1505 r1540 31 31 import org.expeditee.core.Colour; 32 32 import org.expeditee.encryption.CryptographyConstants; 33 import org.expeditee.gui.Browser; 33 34 import org.expeditee.gui.DisplayController; 34 35 import org.expeditee.gui.Frame; … … 86 87 // Update in memory settings 87 88 ProfileManager.ensureDefaultProfile(); 88 System.setProperty("user.name",username);89 Browser.setExpediteeUserName(username); 89 90 UserSettings.UserName.set(username); 90 91 //UserSettings.ProfileName.set(username); 91 UserSettings.ProfileName.set(FrameIO.ConvertToValidFramesetName(username)); 92 final String profileName = FrameIO.ConvertToValidFramesetName(username); 93 UserSettings.ProfileName.set(profileName); 92 94 UserSettings.setupDefaultFolders(); 93 95 94 96 Frame profile; 95 97 try { 96 profile = createNewProfile(username, email, personalKey, privateKey, publicKey);98 profile = createNewProfile(username, profileName, email, personalKey, privateKey, publicKey); 97 99 } catch (InvalidFramesetNameException | ExistingFramesetException e) { 98 100 return CreateResult.ErrorNewProfile; … … 201 203 } 202 204 203 private static Frame createNewProfile(String username, String email, String personalKey, String privateKey,205 private static Frame createNewProfile(String username, String profileName, String email, String personalKey, String privateKey, 204 206 String publicKey) throws InvalidFramesetNameException, ExistingFramesetException { 205 207 // Establish the initial settings for the created user. … … 241 243 242 244 // Create users profile 243 Frame profile = FrameIO.CreateNewProfile(username, initialSettings, notifiers);245 Frame profile = FrameIO.CreateNewProfile(username, profileName, initialSettings, notifiers); 244 246 int lastNumber = FrameIO.getLastNumber(profile.getFramesetName()); 245 247 for (int i = 1; i <= lastNumber; i++) { -
trunk/src/org/expeditee/auth/tags/AuthenticationTag.java
r1368 r1540 9 9 10 10 public enum AuthenticationTag { 11 Username ("txtUsername", System.getProperty("user.name")), 11 Username ("txtUsername", System.getProperty("user.name")), // Should use Browser.getExpediteeUserName() 12 12 Password ("txtPassword", System.getProperty("user.password")), 13 13 PasswordAgain ("txtPasswordAgain", System.getProperty("user.password.again")), -
trunk/src/org/expeditee/gio/swing/SwingGraphicsManager.java
r1432 r1540 197 197 198 198 if (on) { 199 if (hasAntialiasing) { 200 //return; 201 } 199 202 surface.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON); 203 hasAntialiasing = true; 200 204 } else { 205 if (hasAntialiasing) { 206 //return; 207 } 201 208 surface.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_OFF); 202 209 } 203 210 } 211 212 private static boolean hasAntialiasing = false; 204 213 205 214 @Override -
trunk/src/org/expeditee/gui/Browser.java
r1526 r1540 169 169 public static void main(String[] args) { 170 170 if (AuthenticatorBrowser.isAuthenticationRequired()) { 171 String starting_user_name = System.getProperty("user.name");171 String starting_user_name = getExpediteeUserName(); 172 172 System.setProperty("startinguser.name", starting_user_name); 173 System.setProperty("user.name",AuthenticatorBrowser.USER_NOBODY);173 setExpediteeUserName(AuthenticatorBrowser.USER_NOBODY); 174 174 } 175 175 … … 276 276 277 277 if (!AuthenticatorBrowser.isAuthenticationRequired() && UserSettings.PublicAndPrivateResources) { 278 String userName = System.getProperty("user.name"); //UserSettings.ProfileName.get();278 String userName = getExpediteeUserName(); //UserSettings.ProfileName.get(); 279 279 if (!FrameIO.personalResourcesExist(userName)) { 280 280 FrameIO.setupPersonalResources(userName); … … 537 537 }); 538 538 } 539 539 540 private static String expediteeUserName = System.getProperty("user.name"); 541 542 public static String getExpediteeUserName() { 543 // String expediteeUserNameLocal = FrameIO.ConvertToValidFramesetName(expediteeUserName); 544 // return expediteeUserNameLocal; 545 return expediteeUserName; 546 } 547 548 public static void setExpediteeUserName(String username) { 549 expediteeUserName = username; 550 } 551 552 public static String getExpediteeUserProfileName() { 553 String expediteeUserNameLocal = FrameIO.ConvertToValidFramesetName(expediteeUserName); 554 return expediteeUserNameLocal; 555 } 556 540 557 /** 541 558 * @return The user's profile frame. 542 559 */ 543 public static Frame loadInitialProfiles() 544 { 560 public static Frame loadInitialProfiles() { 545 561 String defaultProfileName = UserSettings.DEFAULT_PROFILE_NAME; 546 String userName = System.getProperty("user.name"); 547 548 Frame defaultProfile = loadProfile(defaultProfileName); 549 Frame userProfile = loadProfile(userName); 562 String userName = getExpediteeUserName(); 563 String userProfileName = getExpediteeUserProfileName(); 564 565 Frame defaultProfile = loadProfile(defaultProfileName, defaultProfileName); 566 Frame userProfile = loadProfile(userName, userProfileName); 550 567 551 568 MessageBay.warningMessages(FrameUtils.ParseProfile(defaultProfile)); … … 571 588 } 572 589 573 protected static Frame loadProfile(String user Name) {574 Frame profile = FrameIO.LoadProfile( userName);590 protected static Frame loadProfile(String username, String profileName) { 591 Frame profile = FrameIO.LoadProfile(profileName); 575 592 576 593 if (profile == null) { 577 594 try { 578 profile = FrameIO.CreateNewProfile(user Name, null, null);595 profile = FrameIO.CreateNewProfile(username, profileName, null, null); 579 596 } catch (Exception e) { 580 597 // TODO tell the user that there was a problem creating the -
trunk/src/org/expeditee/gui/FrameIO.java
r1532 r1540 1100 1100 1101 1101 if (toSave == null || !toSave.hasChanged() || toSave.isSaved()) { 1102 System.err.println("FrameIO::SaveFrame::Nothing to save, backing out."); 1102 1103 return ""; 1104 } 1105 1106 if (toSave.getName().toLowerCase().equals("abc146a1")) { 1107 System.out.println("here"); 1103 1108 } 1104 1109 … … 1200 1205 boolean fileModifyConflict = fileLastModify > frameLastModify && !isBayFrameset; 1201 1206 boolean versionConflict = savedVersion > toSave.getVersion() && !isBayFrameset; 1207 1208 System.err.println("FrameIO::SaveFrame::Checking for conflicts for frame:" + toSave.getName()); 1202 1209 1203 1210 if ((fileModifyConflict || versionConflict) && savedVersion > 0) { … … 1405 1412 } 1406 1413 1407 public static Frame LoadProfile(String userName)1414 public static Frame LoadProfile(String profileName) 1408 1415 { 1409 1416 final String profilesLoc = System.getProperty("profiles.loc"); 1410 1417 if (profilesLoc != null) { 1411 return LoadFrame( userName + "1", profilesLoc);1418 return LoadFrame(profileName + "1", profilesLoc); 1412 1419 } else { 1413 return LoadFrame( userName + "1");1414 } 1415 } 1416 1417 public static Frame CreateNewProfile(String user name, Map<String, Setting> initialSettings, Map<String, Consumer<Frame>> toNotifyOnSet) throws InvalidFramesetNameException, ExistingFramesetException {1420 return LoadFrame(profileName + "1"); 1421 } 1422 } 1423 1424 public static Frame CreateNewProfile(String userName, String profileName, Map<String, Setting> initialSettings, Map<String, Consumer<Frame>> toNotifyOnSet) throws InvalidFramesetNameException, ExistingFramesetException { //TODO: Investigate these throws, they never seem to be thrown up this far. 1418 1425 // Frame profile = CreateFrameset(username, PROFILE_PATH, true); 1419 1426 // if (profile != null) { … … 1425 1432 // } 1426 1433 // return profile; 1427 if ( username.equals(UserSettings.DEFAULT_PROFILE_NAME)) {1428 ProfileManager.ensureDefaultProfile();1429 return FrameIO.LoadFrame(UserSettings.DEFAULT_PROFILE_NAME + "1");1434 if (profileName.equals(UserSettings.DEFAULT_PROFILE_NAME)) { 1435 System.err.println("FrameIO::CreateNewProfile::DEPRECATED::CreateNewProfile should no longer be called to create a default profile. Use FrameIO::CreateNewDefaultProfile instead."); 1436 return CreateNewDefaultProfile(); 1430 1437 } else { 1431 return ProfileManager.createProfile(username, initialSettings, toNotifyOnSet); 1432 } 1438 return ProfileManager.createProfile(userName, profileName, initialSettings, toNotifyOnSet); 1439 } 1440 } 1441 1442 public static Frame CreateNewDefaultProfile() throws InvalidFramesetNameException, ExistingFramesetException { //TODO: Investigate these throws, they never seem to be thrown up this far. 1443 ProfileManager.ensureDefaultProfile(); 1444 return FrameIO.LoadFrame(UserSettings.DEFAULT_PROFILE_NAME + "1"); 1433 1445 } 1434 1446 -
trunk/src/org/expeditee/gui/MessageBay.java
r1510 r1540 481 481 } 482 482 483 _authorisedUser = new Text("Username: " + System.getProperty("user.name"));483 _authorisedUser = new Text("Username: " + Browser.getExpediteeUserName()); 484 484 _authorisedUser.setFont(new Font(Text.MONOSPACED_FONT)); 485 485 _authorisedUser.setY(95); -
trunk/src/org/expeditee/gui/management/ProfileManager.java
r1532 r1540 31 31 private static final String[] startPages = { "exploratorysearch", "webbrowser" }; 32 32 public static final String USER_NAME_FLAG = "${" + "USER.NAME" + "}"; 33 34 public static Frame createProfile(String profileFor, Map<String, Setting> specifiedSettings, 33 public static final String PROFILE_NAME_FLAG = "${" + "PROFILE.NAME" + "}"; 34 35 public static Frame createProfile(String username, String profileName, Map<String, Setting> specifiedSettings, 35 36 Map<String, Consumer<Frame>> notifyWhenGenerated) { 36 37 ensureDefaultProfile(); 37 38 Frame profileOne = null; 38 profileFor = FrameIO.ConvertToValidFramesetName(profileFor);39 //String profileName = FrameIO.ConvertToValidFramesetName(username); // TODO: Delete this line before SVN commit 39 40 40 41 try { 41 Frame profile = FrameIO.CreateFrameset(profile For, FrameIO.PROFILE_PATH, true, null);42 Frame profile = FrameIO.CreateFrameset(profileName, FrameIO.PROFILE_PATH, true, null); 42 43 profileOne = profile; 43 profile.setTitle( profileFor+ "'s Profile");44 profile.setTitle(username + "'s Profile"); 44 45 Frame defaultFrame = FrameIO.LoadFrame(DEFAULT + "1"); 45 46 MessageBay.suppressMessages(true); 46 UserSettings.UserName.set( profileFor);47 UserSettings.ProfileName.set( FrameIO.ConvertToValidFramesetName(profileFor));47 UserSettings.UserName.set(username); 48 UserSettings.ProfileName.set(profileName); 48 49 49 50 int lastNumber = FrameIO.getLastNumber(defaultFrame.getFramesetName()); … … 83 84 if (item instanceof Text) { 84 85 String content = item.getText(); 85 item.setText(ResourceUtil.substitute(content, ProfileManager.USER_NAME_FLAG, profileFor)); 86 String contentWithUserSub = ResourceUtil.substitute(content, ProfileManager.USER_NAME_FLAG, username); 87 String contentWithUserAndProfileSub = ResourceUtil.substitute(contentWithUserSub, ProfileManager.PROFILE_NAME_FLAG, FrameIO.ConvertToValidFramesetName(profileName)); 88 item.setText(contentWithUserAndProfileSub); 86 89 } 87 90 } -
trunk/src/org/expeditee/items/Dot.java
r1514 r1540 234 234 } else if (_highlightMode == HighlightMode.Connected) { 235 235 g.drawRectangle(bounds.getTopLeft(), bounds.getSize(), 0.0f, null, highlightColor, HIGHLIGHT_STROKE, null); 236 System.err.println("Dot::paint:Painting Dot with colour: " + highlightColor); 236 237 } else if (_highlightMode == HighlightMode.Normal) { 237 238 g.drawOval(bounds.getCentre(), bounds.getSize(), 0.0f, fill, highlightColor, DOT_STROKE);
Note:
See TracChangeset
for help on using the changeset viewer.