Package com.mucommander.ui.dialog.file

Examples of com.mucommander.ui.dialog.file.FileCollisionDialog


        // Check for file collisions, i.e. if the file already exists in the destination
        int collision = FileCollisionChecker.checkForCollision(null, destFile);
        if(collision!=FileCollisionChecker.NO_COLLOSION) {
            // File already exists in destination, ask the user what to do (cancel, overwrite,...) but
            // do not offer the multiple files mode options such as 'skip' and 'apply to all'.
            int choice = waitForUserResponse(new FileCollisionDialog(getProgressDialog(), getMainFrame(), collision, null, destFile, false, false));

            // Overwrite file
            if (choice== FileCollisionDialog.OVERWRITE_ACTION) {
                // Do nothing, simply continue and file will be overwritten
            }
View Full Code Here


            // Check for file collisions, i.e. if the file already exists in the destination
            int collision = FileCollisionChecker.checkForCollision(null, destFile);
            if(collision!=FileCollisionChecker.NO_COLLOSION) {
                // File already exists in destination, ask the user what to do (cancel, overwrite,...) but
                // do not offer the multiple files mode options such as 'skip' and 'apply to all'.
                int action = new FileCollisionDialog(getFrame(), getFrame()/*mainFrame*/, collision, null, destFile, false, false).getActionValue();

                // User chose to overwrite the file
                if (action== FileCollisionDialog.OVERWRITE_ACTION) {
                    // Do nothing, simply continue and file will be overwritten
                }
View Full Code Here

            // Handle collision, asking the user what to do or using a default action to resolve the collision
            if(collision != FileCollisionChecker.NO_COLLOSION) {
                int choice;
                // Use default action if one has been set, if not show up a dialog
                if(defaultFileExistsAction==FileCollisionDialog.ASK_ACTION) {
                    FileCollisionDialog dialog = new FileCollisionDialog(getProgressDialog(), getMainFrame(), collision, file, destFile, true, true);
                    choice = waitForUserResponse(dialog);
                    // If 'apply to all' was selected, this choice will be used for any other files (user will not be asked again)
                    if(dialog.applyToAllSelected())
                        defaultFileExistsAction = choice;
                }
                else
                    choice = defaultFileExistsAction;
   
View Full Code Here

        // Check for file collisions, i.e. if the file already exists in the destination
        int collision = FileCollisionChecker.checkForCollision(null, checksumFile);
        if(collision!=FileCollisionChecker.NO_COLLOSION) {
            // File already exists in destination, ask the user what to do (cancel, overwrite,...) but
            // do not offer the multiple files mode options such as 'skip' and 'apply to all'.
            int choice = waitForUserResponse(new FileCollisionDialog(getProgressDialog(), getMainFrame(), collision, null, checksumFile, false, false));

            // Overwrite file
            if (choice== FileCollisionDialog.OVERWRITE_ACTION) {
                // Do nothing, simply continue and file will be overwritten
            }
View Full Code Here

                // Check for file collisions, i.e. if the file already exists in the destination
                int collision = FileCollisionChecker.checkForCollision(null, file);
                if(collision!=FileCollisionChecker.NO_COLLOSION) {
                    // File already exists in destination, ask the user what to do (cancel, overwrite,...) but
                    // do not offer the multiple files mode options such as 'skip' and 'apply to all'.
                    int choice = waitForUserResponse(new FileCollisionDialog(getMainFrame(), getMainFrame(), collision, null, file, false, false));

                    // Overwrite file
                    if (choice==FileCollisionDialog.OVERWRITE_ACTION) {
                        // Delete the file
                        file.delete();
View Full Code Here

        AbstractFile destFile = ExtensionManager.getExtensionsFile(library.getName());

        int collision = FileCollisionChecker.checkForCollision(library, destFile);
        if(collision!=FileCollisionChecker.NO_COLLOSION) {
            // Do not offer the multiple files mode options such as 'skip' and 'apply to all'
            int action = new FileCollisionDialog(parent, parent, collision, library, destFile, false, false).getActionValue();

            // User chose to overwrite the file
            if(action==FileCollisionDialog.OVERWRITE_ACTION) {
                // Simply continue and file will be overwritten
            }
View Full Code Here

                    file = lastSelectedFolder.getDirectChild(file.getName()+".xml");

                int collision = FileCollisionChecker.checkForCollision(null, file);
                if(collision!=FileCollisionChecker.NO_COLLOSION) {
                    // Do not offer the multiple files mode options such as 'skip' and 'apply to all'
                    int action = new FileCollisionDialog(parent, parent, collision, null, file, false, false).getActionValue();

                    // User chose to overwrite the file
                    if(action==FileCollisionDialog.OVERWRITE_ACTION) {
                        // Simply continue and file will be overwritten
                    }
View Full Code Here

TOP

Related Classes of com.mucommander.ui.dialog.file.FileCollisionDialog

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.