diff options
| author | Tomas Bzatek <tbzatek@users.sourceforge.net> | 2008-11-14 21:25:58 +0100 |
|---|---|---|
| committer | Tomas Bzatek <tbzatek@users.sourceforge.net> | 2008-11-14 21:25:58 +0100 |
| commit | f51fc44e0d479335b68650016b40813129039322 (patch) | |
| tree | 39e4609156f2fbbfcb3f1b0846588a96e1137211 | |
| parent | 672d925f873c636562f80c6a46e1086e3fe6549a (diff) | |
| download | tuxcmd-f51fc44e0d479335b68650016b40813129039322.tar.xz | |
Disable checksum checking, creating and splitting + merging for VFS engines
| -rw-r--r-- | UMain.pas | 22 |
1 files changed, 14 insertions, 8 deletions
@@ -1691,8 +1691,8 @@ begin end else begin Ext := WideUpperCase(Trim(Copy(String(Data^.FDisplayName), LastDelimiter('.', String(Data^.FDisplayName)) + 1, Length(String(Data^.FDisplayName)) - LastDelimiter('.', String(Data^.FDisplayName))))); // Test for known internal functions - if (Ext = 'SFV') or (Ext = 'MD5') then miVerifyChecksumsClick(Self) else - if (Ext = 'CRC') or (Ext = '001') then miMergeFilesClick(Self) else + if ((Ext = 'SFV') or (Ext = 'MD5')) and (Engine is TLocalTreeEngine) then miVerifyChecksumsClick(Self) else + if ((Ext = 'CRC') or (Ext = '001')) and (Engine is TLocalTreeEngine) then miMergeFilesClick(Self) else if not ((Engine is TLocalTreeEngine) and HandleVFSArchive(String(Data^.FName), IncludeTrailingPathDelimiter(Engine.Path) + String(Data^.FName), String(Data^.FName), '/')) then if (not ConfUseURI) or ((Engine is TVFSEngine) and TVFSEngine(Engine).ArchiveMode) then RunFile(IncludeTrailingPathDelimiter(Engine.Path) + String(Data^.FName), Engine, -1) @@ -1932,17 +1932,23 @@ end; procedure TFMain.UpdateCaption; var LeftPanel: boolean; s: string; + Engine: TPanelEngine; begin if LeftListView.Focused then LeftPanel := True else if RightListView.Focused then LeftPanel := False else LeftPanel := LeftLastFocused; - if LeftPanel then begin - if LeftPanelEngine.GetPrefix <> '' then s := Format(ConstFullPathFormatStr, [LeftPanelEngine.GetPrefix, LeftPanelEngine.Path]) - else s := LeftPanelEngine.Path; - end else - if RightPanelEngine.GetPrefix <> '' then s := Format(ConstFullPathFormatStr, [RightPanelEngine.GetPrefix, RightPanelEngine.Path]) - else s := RightPanelEngine.Path; + + if LeftPanel then Engine := LeftPanelEngine + else Engine := RightPanelEngine; + + if Engine.GetPrefix <> '' then s := Format(ConstFullPathFormatStr, [Engine.GetPrefix, Engine.Path]) + else s := Engine.Path; Caption := Format('Tux Commander [%s]', [StrToUTF8(s)]); + + miVerifyChecksums.Enabled := Engine is TLocalTreeEngine; + miCreateChecksums.Enabled := Engine is TLocalTreeEngine; + miSplitFile.Enabled := Engine is TLocalTreeEngine; + miMergeFiles.Enabled := Engine is TLocalTreeEngine; end; procedure TFMain.UpdatePanelInfo; |
