mirror of
				https://github.com/davidgiven/fluxengine.git
				synced 2025-10-24 11:11:02 -07:00 
			
		
		
		
	Split the Layout class.
This commit is contained in:
		| @@ -110,7 +110,7 @@ public: | ||||
|     } | ||||
|  | ||||
| public: | ||||
|     std::unique_ptr<Fluxmap> encode(std::shared_ptr<const Layout>& layout, | ||||
|     std::unique_ptr<Fluxmap> encode(std::shared_ptr<const Track>& layout, | ||||
|         const std::vector<std::shared_ptr<const Sector>>& sectors, | ||||
|         const Image& image) override | ||||
|     { | ||||
|   | ||||
| @@ -36,7 +36,7 @@ private: | ||||
|     const Apple2EncoderProto& _config; | ||||
|  | ||||
| public: | ||||
|     std::unique_ptr<Fluxmap> encode(std::shared_ptr<const Layout>& layout, | ||||
|     std::unique_ptr<Fluxmap> encode(std::shared_ptr<const Track>& layout, | ||||
|         const std::vector<std::shared_ptr<const Sector>>& sectors, | ||||
|         const Image& image) override | ||||
|     { | ||||
|   | ||||
| @@ -108,7 +108,7 @@ public: | ||||
|  | ||||
| public: | ||||
|     std::unique_ptr<Fluxmap> encode( | ||||
| 		std::shared_ptr<const Layout>& layout, | ||||
| 		std::shared_ptr<const Track>& layout, | ||||
|         const std::vector<std::shared_ptr<const Sector>>& sectors, | ||||
|         const Image& image) override | ||||
|     { | ||||
|   | ||||
| @@ -175,7 +175,7 @@ public: | ||||
|     } | ||||
|  | ||||
| public: | ||||
|     std::unique_ptr<Fluxmap> encode(std::shared_ptr<const Layout>& layout, | ||||
|     std::unique_ptr<Fluxmap> encode(std::shared_ptr<const Track>& layout, | ||||
|         const std::vector<std::shared_ptr<const Sector>>& sectors, | ||||
|         const Image& image) override | ||||
|     { | ||||
|   | ||||
| @@ -107,7 +107,7 @@ private: | ||||
|     } | ||||
|  | ||||
| public: | ||||
|     std::unique_ptr<Fluxmap> encode(std::shared_ptr<const Layout>& layout, | ||||
|     std::unique_ptr<Fluxmap> encode(std::shared_ptr<const Track>& layout, | ||||
|         const std::vector<std::shared_ptr<const Sector>>& sectors, | ||||
|         const Image& image) override | ||||
|     { | ||||
|   | ||||
| @@ -220,7 +220,7 @@ public: | ||||
|     } | ||||
|  | ||||
| public: | ||||
|     std::unique_ptr<Fluxmap> encode(std::shared_ptr<const Layout>& layout, | ||||
|     std::unique_ptr<Fluxmap> encode(std::shared_ptr<const Track>& layout, | ||||
|         const std::vector<std::shared_ptr<const Sector>>& sectors, | ||||
|         const Image& image) override | ||||
|     { | ||||
|   | ||||
| @@ -77,7 +77,7 @@ public: | ||||
|     { | ||||
|     } | ||||
|  | ||||
|     std::unique_ptr<Fluxmap> encode(std::shared_ptr<const Layout>& layout, | ||||
|     std::unique_ptr<Fluxmap> encode(std::shared_ptr<const Track>& layout, | ||||
|         const std::vector<std::shared_ptr<const Sector>>& sectors, | ||||
|         const Image& image) override | ||||
|     { | ||||
|   | ||||
| @@ -128,7 +128,7 @@ public: | ||||
|     { | ||||
|     } | ||||
|  | ||||
|     std::unique_ptr<Fluxmap> encode(std::shared_ptr<const Layout>& layout, | ||||
|     std::unique_ptr<Fluxmap> encode(std::shared_ptr<const Track>& layout, | ||||
|         const std::vector<std::shared_ptr<const Sector>>& sectors, | ||||
|         const Image& image) override | ||||
|     { | ||||
|   | ||||
| @@ -60,7 +60,7 @@ private: | ||||
|     } | ||||
|  | ||||
| public: | ||||
|     std::unique_ptr<Fluxmap> encode(std::shared_ptr<const Layout>& layout, | ||||
|     std::unique_ptr<Fluxmap> encode(std::shared_ptr<const Track>& layout, | ||||
|         const std::vector<std::shared_ptr<const Sector>>& sectors, | ||||
|         const Image& image) override | ||||
|     { | ||||
|   | ||||
| @@ -164,7 +164,7 @@ private: | ||||
|     } | ||||
|  | ||||
| public: | ||||
|     std::unique_ptr<Fluxmap> encode(std::shared_ptr<const Layout>& layout, | ||||
|     std::unique_ptr<Fluxmap> encode(std::shared_ptr<const Track>& layout, | ||||
|         const std::vector<std::shared_ptr<const Sector>>& sectors, | ||||
|         const Image& image) override | ||||
|     { | ||||
|   | ||||
| @@ -61,7 +61,7 @@ std::unique_ptr<Decoder> Decoder::create(const DecoderProto& config) | ||||
| } | ||||
|  | ||||
| std::shared_ptr<TrackDataFlux> Decoder::decodeToSectors( | ||||
|     std::shared_ptr<const Fluxmap> fluxmap, std::shared_ptr<const Layout>& layout) | ||||
|     std::shared_ptr<const Fluxmap> fluxmap, std::shared_ptr<const Track>& layout) | ||||
| { | ||||
|     _trackdata = std::make_shared<TrackDataFlux>(); | ||||
|     _trackdata->fluxmap = fluxmap; | ||||
| @@ -222,7 +222,7 @@ uint64_t Decoder::readRaw64() | ||||
| } | ||||
|  | ||||
| std::set<LogicalLocation> Decoder::requiredSectors( | ||||
|     std::shared_ptr<const Layout>& layout) const | ||||
|     std::shared_ptr<const Track>& layout) const | ||||
| { | ||||
|     const auto trackLayout = | ||||
|         Layout::getLayoutOfTrackPhysical(layout->physicalTrack, layout->physicalSide); | ||||
|   | ||||
| @@ -51,7 +51,7 @@ public: | ||||
| public: | ||||
|     std::shared_ptr<TrackDataFlux> decodeToSectors( | ||||
|         std::shared_ptr<const Fluxmap> fluxmap, | ||||
|         std::shared_ptr<const Layout>& location); | ||||
|         std::shared_ptr<const Track>& location); | ||||
|  | ||||
|     void pushRecord( | ||||
|         const Fluxmap::Position& start, const Fluxmap::Position& end); | ||||
| @@ -90,7 +90,7 @@ public: | ||||
|     } | ||||
|  | ||||
|     virtual std::set<LogicalLocation> requiredSectors( | ||||
|         std::shared_ptr<const Layout>& location) const; | ||||
|         std::shared_ptr<const Track>& location) const; | ||||
|  | ||||
| protected: | ||||
|     virtual void beginTrack(){}; | ||||
|   | ||||
| @@ -57,13 +57,13 @@ nanoseconds_t Encoder::calculatePhysicalClockPeriod( | ||||
| } | ||||
|  | ||||
| std::shared_ptr<const Sector> Encoder::getSector( | ||||
|     std::shared_ptr<const Layout>& layout, const Image& image, unsigned sectorId) | ||||
|     std::shared_ptr<const Track>& layout, const Image& image, unsigned sectorId) | ||||
| { | ||||
|     return image.get(layout->logicalTrack, layout->logicalSide, sectorId); | ||||
| } | ||||
|  | ||||
| std::vector<std::shared_ptr<const Sector>> Encoder::collectSectors( | ||||
|     std::shared_ptr<const Layout>& trackLayout, const Image& image) | ||||
|     std::shared_ptr<const Track>& trackLayout, const Image& image) | ||||
| { | ||||
|     std::vector<std::shared_ptr<const Sector>> sectors; | ||||
|  | ||||
|   | ||||
| @@ -17,12 +17,12 @@ public: | ||||
|  | ||||
| public: | ||||
|     virtual std::shared_ptr<const Sector> getSector( | ||||
|         std::shared_ptr<const Layout>&, const Image& image, unsigned sectorId); | ||||
|         std::shared_ptr<const Track>&, const Image& image, unsigned sectorId); | ||||
|  | ||||
|     virtual std::vector<std::shared_ptr<const Sector>> collectSectors( | ||||
|         std::shared_ptr<const Layout>&, const Image& image); | ||||
|         std::shared_ptr<const Track>&, const Image& image); | ||||
|  | ||||
|     virtual std::unique_ptr<Fluxmap> encode(std::shared_ptr<const Layout>& layout, | ||||
|     virtual std::unique_ptr<Fluxmap> encode(std::shared_ptr<const Track>& layout, | ||||
|         const std::vector<std::shared_ptr<const Sector>>& sectors, | ||||
|         const Image& image) = 0; | ||||
|  | ||||
|   | ||||
| @@ -6,7 +6,7 @@ | ||||
| class Fluxmap; | ||||
| class Sector; | ||||
| class Image; | ||||
| class Layout; | ||||
| class Track; | ||||
|  | ||||
| struct Record | ||||
| { | ||||
| @@ -18,7 +18,7 @@ struct Record | ||||
|  | ||||
| struct TrackDataFlux | ||||
| { | ||||
| 	std::shared_ptr<const Layout> layout; | ||||
| 	std::shared_ptr<const Track> layout; | ||||
| 	std::shared_ptr<const Fluxmap> fluxmap; | ||||
| 	std::vector<std::shared_ptr<const Record>> records; | ||||
| 	std::vector<std::shared_ptr<const Sector>> sectors; | ||||
| @@ -26,7 +26,7 @@ struct TrackDataFlux | ||||
|  | ||||
| struct TrackFlux | ||||
| { | ||||
| 	std::shared_ptr<const Layout> layout; | ||||
| 	std::shared_ptr<const Track> layout; | ||||
| 	std::vector<std::shared_ptr<TrackDataFlux>> trackDatas; | ||||
| 	std::set<std::shared_ptr<const Sector>> sectors; | ||||
| }; | ||||
|   | ||||
| @@ -4,7 +4,7 @@ | ||||
| #include "lib/environment.h" | ||||
| #include <fmt/format.h> | ||||
|  | ||||
| static Local<std::map<std::pair<int, int>, std::shared_ptr<Layout>>> | ||||
| static Local<std::map<std::pair<int, int>, std::shared_ptr<Track>>> | ||||
|     layoutCache; | ||||
|  | ||||
| static unsigned getTrackStep() | ||||
| @@ -38,7 +38,7 @@ unsigned Layout::remapSideLogicalToPhysical(unsigned lside) | ||||
|     return lside ^ config.layout().swap_sides(); | ||||
| } | ||||
|  | ||||
| std::vector<std::shared_ptr<const Layout>> Layout::computeLocations() | ||||
| std::vector<std::shared_ptr<const Track>> Layout::computeLocations() | ||||
| { | ||||
|     std::set<unsigned> tracks; | ||||
|     if (config.has_tracks()) | ||||
| @@ -52,7 +52,7 @@ std::vector<std::shared_ptr<const Layout>> Layout::computeLocations() | ||||
|     else | ||||
|         heads = iterate(0, config.layout().sides()); | ||||
|  | ||||
|     std::vector<std::shared_ptr<const Layout>> locations; | ||||
|     std::vector<std::shared_ptr<const Track>> locations; | ||||
|     for (unsigned logicalTrack : tracks) | ||||
|     { | ||||
|         for (unsigned logicalHead : heads) | ||||
| @@ -125,13 +125,13 @@ std::vector<unsigned> Layout::expandSectorList( | ||||
|     return sectors; | ||||
| } | ||||
|  | ||||
| std::shared_ptr<const Layout> Layout::getLayoutOfTrack( | ||||
| std::shared_ptr<const Track> Layout::getLayoutOfTrack( | ||||
|     unsigned logicalTrack, unsigned logicalSide) | ||||
| { | ||||
|     auto& layout = (*layoutCache)[std::make_pair(logicalTrack, logicalSide)]; | ||||
|     if (!layout) | ||||
|     { | ||||
|     	layout = std::make_shared<Layout>(); | ||||
|     	layout = std::make_shared<Track>(); | ||||
|  | ||||
|         LayoutProto::LayoutdataProto layoutdata; | ||||
|         for (const auto& f : config.layout().layoutdata()) | ||||
| @@ -190,7 +190,7 @@ std::shared_ptr<const Layout> Layout::getLayoutOfTrack( | ||||
|     return layout; | ||||
| } | ||||
|  | ||||
| std::shared_ptr<const Layout> Layout::getLayoutOfTrackPhysical( | ||||
| std::shared_ptr<const Track> Layout::getLayoutOfTrackPhysical( | ||||
|     unsigned physicalTrack, unsigned physicalSide) | ||||
| { | ||||
|     return getLayoutOfTrack(remapTrackPhysicalToLogical(physicalTrack), | ||||
|   | ||||
							
								
								
									
										25
									
								
								lib/layout.h
									
									
									
									
									
								
							
							
						
						
									
										25
									
								
								lib/layout.h
									
									
									
									
									
								
							| @@ -4,17 +4,10 @@ | ||||
| #include "lib/flux.h" | ||||
|  | ||||
| class SectorListProto; | ||||
| class Track; | ||||
|  | ||||
| class Layout | ||||
| { | ||||
| public: | ||||
|     Layout() {} | ||||
|  | ||||
| private: | ||||
|     /* Can't copy. */ | ||||
|     Layout(const Layout&); | ||||
|     Layout& operator=(const Layout&); | ||||
|  | ||||
| public: | ||||
|     /* Translates logical track numbering (the numbers actually written in the | ||||
|      * sector headers) to the track numbering on the actual drive, taking into | ||||
| @@ -32,7 +25,7 @@ public: | ||||
|     /* Uses the layout and current track and heads settings to determine | ||||
|      * which Locations are going to be read from or written to. 8/ | ||||
|      */ | ||||
|     static std::vector<std::shared_ptr<const Layout>> computeLocations(); | ||||
|     static std::vector<std::shared_ptr<const Track>> computeLocations(); | ||||
|  | ||||
|     /* Returns a series of <track, side> pairs representing the filesystem | ||||
|      * ordering of the disk, in logical numbers. */ | ||||
| @@ -40,16 +33,26 @@ public: | ||||
|         unsigned guessedTracks = 0, unsigned guessedSides = 0); | ||||
|  | ||||
|     /* Returns the layout of a given track. */ | ||||
|     static std::shared_ptr<const Layout> getLayoutOfTrack( | ||||
|     static std::shared_ptr<const Track> getLayoutOfTrack( | ||||
|         unsigned logicalTrack, unsigned logicalHead); | ||||
|  | ||||
|     /* Returns the layout of a given track via physical location. */ | ||||
|     static std::shared_ptr<const Layout> getLayoutOfTrackPhysical( | ||||
|     static std::shared_ptr<const Track> getLayoutOfTrackPhysical( | ||||
|         unsigned physicalTrack, unsigned physicalSide); | ||||
|  | ||||
|     /* Expand a SectorList into the actual sector IDs. */ | ||||
|     static std::vector<unsigned> expandSectorList( | ||||
|         const SectorListProto& sectorsProto); | ||||
| }; | ||||
|  | ||||
| class Track { | ||||
| public: | ||||
| 	Track() {} | ||||
|  | ||||
| private: | ||||
|     /* Can't copy. */ | ||||
|     Track(const Track&); | ||||
|     Track& operator=(const Track&); | ||||
|  | ||||
| public: | ||||
|     unsigned numTracks = 0; | ||||
|   | ||||
| @@ -156,7 +156,7 @@ static std::set<std::shared_ptr<const Sector>> collectSectors( | ||||
|  | ||||
| BadSectorsState combineRecordAndSectors(TrackFlux& trackFlux, | ||||
|     Decoder& decoder, | ||||
|     std::shared_ptr<const Layout>& layout) | ||||
|     std::shared_ptr<const Track>& layout) | ||||
| { | ||||
|     std::set<std::shared_ptr<const Sector>> track_sectors; | ||||
|  | ||||
| @@ -182,7 +182,7 @@ BadSectorsState combineRecordAndSectors(TrackFlux& trackFlux, | ||||
| } | ||||
|  | ||||
| ReadResult readGroup(FluxSourceIteratorHolder& fluxSourceIteratorHolder, | ||||
|     std::shared_ptr<const Layout>& layout, | ||||
|     std::shared_ptr<const Track>& layout, | ||||
|     TrackFlux& trackFlux, | ||||
|     Decoder& decoder) | ||||
| { | ||||
| @@ -224,9 +224,9 @@ ReadResult readGroup(FluxSourceIteratorHolder& fluxSourceIteratorHolder, | ||||
|  | ||||
| void writeTracks(FluxSink& fluxSink, | ||||
|     std::function<std::unique_ptr<const Fluxmap>( | ||||
|         std::shared_ptr<const Layout>& layout)> producer, | ||||
|     std::function<bool(std::shared_ptr<const Layout>& layout)> verifier, | ||||
|     std::vector<std::shared_ptr<const Layout>>& layouts) | ||||
|         std::shared_ptr<const Track>& layout)> producer, | ||||
|     std::function<bool(std::shared_ptr<const Track>& layout)> verifier, | ||||
|     std::vector<std::shared_ptr<const Track>>& layouts) | ||||
| { | ||||
|     Logger() << BeginOperationLogMessage{"Encoding and writing to disk"}; | ||||
|  | ||||
| @@ -294,11 +294,11 @@ void writeTracks(FluxSink& fluxSink, | ||||
| void writeTracks(FluxSink& fluxSink, | ||||
|     Encoder& encoder, | ||||
|     const Image& image, | ||||
|     std::vector<std::shared_ptr<const Layout>>& layouts) | ||||
|     std::vector<std::shared_ptr<const Track>>& layouts) | ||||
| { | ||||
|     writeTracks( | ||||
|         fluxSink, | ||||
|         [&](std::shared_ptr<const Layout>& layout) | ||||
|         [&](std::shared_ptr<const Track>& layout) | ||||
|         { | ||||
|             auto sectors = encoder.collectSectors(layout, image); | ||||
|             return encoder.encode(layout, sectors, image); | ||||
| @@ -315,16 +315,16 @@ void writeTracksAndVerify(FluxSink& fluxSink, | ||||
|     FluxSource& fluxSource, | ||||
|     Decoder& decoder, | ||||
|     const Image& image, | ||||
|     std::vector<std::shared_ptr<const Layout>>& locations) | ||||
|     std::vector<std::shared_ptr<const Track>>& locations) | ||||
| { | ||||
|     writeTracks( | ||||
|         fluxSink, | ||||
|         [&](std::shared_ptr<const Layout>& layout) | ||||
|         [&](std::shared_ptr<const Track>& layout) | ||||
|         { | ||||
|             auto sectors = encoder.collectSectors(layout, image); | ||||
|             return encoder.encode(layout, sectors, image); | ||||
|         }, | ||||
|         [&](std::shared_ptr<const Layout>& layout) | ||||
|         [&](std::shared_ptr<const Track>& layout) | ||||
|         { | ||||
|             auto trackFlux = std::make_shared<TrackFlux>(); | ||||
|             trackFlux->layout = layout; | ||||
| @@ -381,7 +381,7 @@ void writeDiskCommand(const Image& image, | ||||
|     FluxSink& fluxSink, | ||||
|     Decoder* decoder, | ||||
|     FluxSource* fluxSource, | ||||
|     std::vector<std::shared_ptr<const Layout>>& locations) | ||||
|     std::vector<std::shared_ptr<const Track>>& locations) | ||||
| { | ||||
|     if (fluxSource && decoder) | ||||
|         writeTracksAndVerify( | ||||
| @@ -405,7 +405,7 @@ void writeRawDiskCommand(FluxSource& fluxSource, FluxSink& fluxSink) | ||||
| 	auto locations = Layout::computeLocations(); | ||||
|     writeTracks( | ||||
|         fluxSink, | ||||
|         [&](std::shared_ptr<const Layout>& layout) | ||||
|         [&](std::shared_ptr<const Track>& layout) | ||||
|         { | ||||
|             return fluxSource | ||||
|                 .readFlux(layout->physicalTrack, layout->physicalSide) | ||||
| @@ -420,7 +420,7 @@ void writeRawDiskCommand(FluxSource& fluxSource, FluxSink& fluxSink) | ||||
|  | ||||
| std::shared_ptr<TrackFlux> readAndDecodeTrack(FluxSource& fluxSource, | ||||
|     Decoder& decoder, | ||||
|     std::shared_ptr<const Layout>& layout) | ||||
|     std::shared_ptr<const Track>& layout) | ||||
| { | ||||
|     auto trackFlux = std::make_shared<TrackFlux>(); | ||||
|     trackFlux->layout = layout; | ||||
|   | ||||
| @@ -11,7 +11,7 @@ class Fluxmap; | ||||
| class Image; | ||||
| class ImageReader; | ||||
| class ImageWriter; | ||||
| class Layout; | ||||
| class Track; | ||||
| class TrackFlux; | ||||
|  | ||||
| extern void measureDiskRotation( | ||||
| @@ -19,15 +19,15 @@ extern void measureDiskRotation( | ||||
|  | ||||
| extern void writeTracks(FluxSink& fluxSink, | ||||
|     const std::function<std::unique_ptr<const Fluxmap>( | ||||
|         std::shared_ptr<const Layout>& layout)> producer, | ||||
|     std::vector<std::shared_ptr<const Layout>>& locations); | ||||
|         std::shared_ptr<const Track>& layout)> producer, | ||||
|     std::vector<std::shared_ptr<const Track>>& locations); | ||||
|  | ||||
| extern void writeTracksAndVerify(FluxSink& fluxSink, | ||||
|     Encoder& encoder, | ||||
|     FluxSource& fluxSource, | ||||
|     Decoder& decoder, | ||||
|     const Image& image, | ||||
|     std::vector<std::shared_ptr<const Layout>>& locations); | ||||
|     std::vector<std::shared_ptr<const Track>>& locations); | ||||
|  | ||||
| extern void fillBitmapTo(std::vector<bool>& bitmap, | ||||
|     unsigned& cursor, | ||||
| @@ -39,7 +39,7 @@ extern void writeDiskCommand(const Image& image, | ||||
|     FluxSink& fluxSink, | ||||
|     Decoder* decoder, | ||||
|     FluxSource* fluxSource, | ||||
|     std::vector<std::shared_ptr<const Layout>>& locations); | ||||
|     std::vector<std::shared_ptr<const Track>>& locations); | ||||
|  | ||||
| extern void writeDiskCommand(const Image& image, | ||||
|     Encoder& encoder, | ||||
| @@ -51,7 +51,7 @@ extern void writeRawDiskCommand(FluxSource& fluxSource, FluxSink& fluxSink); | ||||
|  | ||||
| extern std::shared_ptr<TrackFlux> readAndDecodeTrack(FluxSource& fluxSource, | ||||
|     Decoder& decoder, | ||||
|     std::shared_ptr<const Layout>& layout); | ||||
|     std::shared_ptr<const Track>& layout); | ||||
|  | ||||
| extern std::shared_ptr<const DiskFlux> readDiskCommand( | ||||
|     FluxSource& fluxsource, Decoder& decoder); | ||||
|   | ||||
| @@ -10,7 +10,7 @@ Sector::Sector(const LogicalLocation& location): | ||||
| 	physicalSide(Layout::remapSideLogicalToPhysical(location.logicalSide)) | ||||
| {} | ||||
|  | ||||
| Sector::Sector(std::shared_ptr<const Layout>& layout, unsigned sectorId): | ||||
| Sector::Sector(std::shared_ptr<const Track>& layout, unsigned sectorId): | ||||
| 	LogicalLocation({ layout->logicalTrack, layout->logicalSide, sectorId }), | ||||
|     physicalTrack(layout->physicalTrack), | ||||
|     physicalSide(layout->physicalSide) | ||||
|   | ||||
| @@ -5,7 +5,7 @@ | ||||
| #include "fluxmap.h" | ||||
|  | ||||
| class Record; | ||||
| class Layout; | ||||
| class Track; | ||||
|  | ||||
| struct LogicalLocation | ||||
| { | ||||
| @@ -65,7 +65,7 @@ struct Sector : public LogicalLocation | ||||
|  | ||||
|     Sector() {} | ||||
|  | ||||
|     Sector(std::shared_ptr<const Layout>& layout, unsigned sectorId=0); | ||||
|     Sector(std::shared_ptr<const Track>& layout, unsigned sectorId=0); | ||||
|  | ||||
|     Sector(const LogicalLocation& location); | ||||
|  | ||||
|   | ||||
| @@ -56,7 +56,7 @@ public: | ||||
|  | ||||
|     void flushChanges() override | ||||
|     { | ||||
|         std::vector<std::shared_ptr<const Layout>> locations; | ||||
|         std::vector<std::shared_ptr<const Track>> locations; | ||||
|  | ||||
|         for (const auto& trackid : _changedTracks) | ||||
|         { | ||||
|   | ||||
| @@ -434,7 +434,7 @@ void FluxViewerControl::ShowSectorMenu(std::shared_ptr<const Sector> sector) | ||||
|     PopupMenu(&menu, _mouseX, _mouseY); | ||||
| } | ||||
|  | ||||
| void FluxViewerControl::ShowRecordMenu(std::shared_ptr<const ::Layout>& layout, | ||||
| void FluxViewerControl::ShowRecordMenu(std::shared_ptr<const Track>& layout, | ||||
|     std::shared_ptr<const Record> record) | ||||
| { | ||||
|     wxMenu menu; | ||||
| @@ -502,7 +502,7 @@ void FluxViewerControl::DisplayRawData(std::shared_ptr<const Sector> sector) | ||||
|     TextViewerWindow::Create(this, title, s.str())->Show(); | ||||
| } | ||||
|  | ||||
| void FluxViewerControl::DisplayRawData(std::shared_ptr<const ::Layout>& layout, | ||||
| void FluxViewerControl::DisplayRawData(std::shared_ptr<const Track>& layout, | ||||
|     std::shared_ptr<const Record> record) | ||||
| { | ||||
|     std::stringstream s; | ||||
|   | ||||
| @@ -8,7 +8,7 @@ class wxScrollBar; | ||||
| class wxScrollEvent; | ||||
| class Sector; | ||||
| class Record; | ||||
| class Layout; | ||||
| class Track; | ||||
|  | ||||
| class FluxViewerControl : public wxWindow | ||||
| { | ||||
| @@ -27,11 +27,11 @@ public: | ||||
| private: | ||||
|     void UpdateScale(); | ||||
|     void ShowSectorMenu(std::shared_ptr<const Sector> sector); | ||||
|     void ShowRecordMenu(std::shared_ptr<const ::Layout>& layout, | ||||
|     void ShowRecordMenu(std::shared_ptr<const Track>& layout, | ||||
|         std::shared_ptr<const Record> record); | ||||
|     void DisplayDecodedData(std::shared_ptr<const Sector> sector); | ||||
|     void DisplayRawData(std::shared_ptr<const Sector> sector); | ||||
|     void DisplayRawData(std::shared_ptr<const ::Layout>& layout, | ||||
|     void DisplayRawData(std::shared_ptr<const Track>& layout, | ||||
|         std::shared_ptr<const Record> record); | ||||
|  | ||||
| private: | ||||
|   | ||||
		Reference in New Issue
	
	Block a user