Skip to content

Commit

Permalink
[#72] Dumping (Part 34: Mustn't override target medium/encoding when …
Browse files Browse the repository at this point in the history
…dumping low-level tracks)
  • Loading branch information
tomas-nestorovic committed Jun 6, 2024
1 parent 553c4f4 commit ffcecdf
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions Main/src/Image_Dump.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1031,6 +1031,8 @@ terminateWithError: return LOG_ERROR(pAction->TerminateWithError(err));
dos->formatBoot.mediumType,
targetImageProperties
);
// : can change Medium only when Source has no explicit Track timing
EnableDlgItem( ID_MEDIUM, dos->image->WriteTrack(0,0,CImage::CTrackReaderWriter::Invalid)==ERROR_NOT_SUPPORTED );
// : preselection of current MediumType (if any recognized)
Medium::TType mt=Medium::UNKNOWN; // assumption (Medium not recognized)
dos->image->GetInsertedMediumType( 0, mt );
Expand All @@ -1054,6 +1056,8 @@ terminateWithError: return LOG_ERROR(pAction->TerminateWithError(err));
dos->properties->supportedCodecs,
mt!=Medium::UNKNOWN ? targetImageProperties : nullptr
);
// : can change Codec only when Source has no explicit Track timing
EnableDlgItem( ID_CODEC, dos->image->WriteTrack(0,0,CImage::CTrackReaderWriter::Invalid)==ERROR_NOT_SUPPORTED );
// : enabling/disabling controls
static constexpr WORD Controls[]={ ID_CYLINDER, ID_CYLINDER_N, ID_HEAD, ID_GAP, ID_NUMBER, ID_DEFAULT1, IDOK, 0 };
CheckAndEnableDlgItem(
Expand Down

0 comments on commit ffcecdf

Please sign in to comment.