SWFs in zip based bundles can be modified & saved

This commit is contained in:
Jindra Petřík
2015-03-07 07:39:44 +01:00
parent 796c9bf3ae
commit 99ec0a592c
17 changed files with 205 additions and 77 deletions

View File

@@ -17,6 +17,7 @@
package com.jpexs.decompiler.flash.gui;
import com.jpexs.decompiler.flash.SWF;
import com.jpexs.decompiler.flash.SWFBundle;
import com.jpexs.decompiler.flash.configuration.Configuration;
import com.jpexs.decompiler.flash.console.ContextMenuTools;
import com.jpexs.decompiler.flash.tags.ABCContainerTag;
@@ -728,8 +729,8 @@ public class MainFrameRibbonMenu extends MainFrameMenu implements ActionListener
closeFileMenu.setEnabled(swfLoaded);
closeAllFilesMenu.setEnabled(swfLoaded);
boolean isBundle = swfLoaded && (swf.swfList != null) && swf.swfList.isBundle;
saveCommandButton.setEnabled(swfLoaded && !isBundle);
boolean isBundle = swfLoaded && (swf.swfList != null) && (swf.swfList.bundle != null);
saveCommandButton.setEnabled(swfLoaded && ((!isBundle) || (!swf.swfList.bundle.isReadOnly())));
saveasCommandButton.setEnabled(swfLoaded);
saveasexeCommandButton.setEnabled(swfLoaded);
exportAllCommandButton.setEnabled(swfLoaded);