Fixes for Visual Studio project file; minor formatting cleanups.

This commit is contained in:
Stephen Anthony 2017-10-01 16:49:29 -02:30
parent 924e92214f
commit 05b2684421
10 changed files with 117 additions and 118 deletions

View File

@ -17,13 +17,14 @@
#include "AmigaMouseWidget.hxx"
AmigaMouseWidget::AmigaMouseWidget(GuiObject* boss, const GUI::Font& font, int x, int y,
Controller& controller)
AmigaMouseWidget::AmigaMouseWidget(GuiObject* boss, const GUI::Font& font,
int x, int y, Controller& controller)
: PointingDeviceWidget(boss, font, x, y, controller)
{}
{
}
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
uInt8 AmigaMouseWidget::getGrayCodeTable(const int index, const int direction)
{
return myGrayCodeTable[index];
}
}

View File

@ -23,24 +23,23 @@
class AmigaMouseWidget : public PointingDeviceWidget
{
public:
AmigaMouseWidget(GuiObject* boss, const GUI::Font& font, int x, int y,
Controller& controller);
public:
AmigaMouseWidget(GuiObject* boss, const GUI::Font& font, int x, int y,
Controller& controller);
virtual ~AmigaMouseWidget() = default;
virtual ~AmigaMouseWidget() = default;
private:
uInt8 myGrayCodeTable[4] = { 0b00, 0b10, 0b11, 0b01 };
private:
uInt8 myGrayCodeTable[4] = { 0b00, 0b10, 0b11, 0b01 };
uInt8 getGrayCodeTable(const int index, const int direction);
uInt8 getGrayCodeTable(const int index, const int direction) override;
// Following constructors and assignment operators not supported
AmigaMouseWidget() = delete;
AmigaMouseWidget(const AmigaMouseWidget&) = delete;
AmigaMouseWidget(AmigaMouseWidget&&) = delete;
AmigaMouseWidget& operator=(const AmigaMouseWidget&) = delete;
AmigaMouseWidget& operator=(AmigaMouseWidget&&) = delete;
// Following constructors and assignment operators not supported
AmigaMouseWidget() = delete;
AmigaMouseWidget(const AmigaMouseWidget&) = delete;
AmigaMouseWidget(AmigaMouseWidget&&) = delete;
AmigaMouseWidget& operator=(const AmigaMouseWidget&) = delete;
AmigaMouseWidget& operator=(AmigaMouseWidget&&) = delete;
};
#endif

View File

@ -17,13 +17,14 @@
#include "AtariMouseWidget.hxx"
AtariMouseWidget::AtariMouseWidget(GuiObject* boss, const GUI::Font& font, int x, int y,
Controller& controller)
AtariMouseWidget::AtariMouseWidget(GuiObject* boss, const GUI::Font& font,
int x, int y, Controller& controller)
: PointingDeviceWidget(boss, font, x, y, controller)
{}
{
}
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
uInt8 AtariMouseWidget::getGrayCodeTable(const int index, const int direction)
{
return myGrayCodeTable[index];
}
}

View File

@ -23,23 +23,23 @@
class AtariMouseWidget : public PointingDeviceWidget
{
public:
AtariMouseWidget(GuiObject* boss, const GUI::Font& font, int x, int y,
Controller& controller);
public:
AtariMouseWidget(GuiObject* boss, const GUI::Font& font, int x, int y,
Controller& controller);
virtual ~AtariMouseWidget() = default;
virtual ~AtariMouseWidget() = default;
private:
uInt8 myGrayCodeTable[4] = { 0b00, 0b01, 0b11, 0b10 };
private:
uInt8 myGrayCodeTable[4] = { 0b00, 0b01, 0b11, 0b10 };
uInt8 getGrayCodeTable(const int index, const int direction);
uInt8 getGrayCodeTable(const int index, const int direction) override;
// Following constructors and assignment operators not supported
AtariMouseWidget() = delete;
AtariMouseWidget(const AtariMouseWidget&) = delete;
AtariMouseWidget(AtariMouseWidget&&) = delete;
AtariMouseWidget& operator=(const AtariMouseWidget&) = delete;
AtariMouseWidget& operator=(AtariMouseWidget&&) = delete;
// Following constructors and assignment operators not supported
AtariMouseWidget() = delete;
AtariMouseWidget(const AtariMouseWidget&) = delete;
AtariMouseWidget(AtariMouseWidget&&) = delete;
AtariMouseWidget& operator=(const AtariMouseWidget&) = delete;
AtariMouseWidget& operator=(AtariMouseWidget&&) = delete;
};
#endif

View File

@ -19,8 +19,8 @@
#include "DataGridWidget.hxx"
#include "PointingDeviceWidget.hxx"
PointingDeviceWidget::PointingDeviceWidget(GuiObject* boss, const GUI::Font& font, int x, int y,
Controller& controller)
PointingDeviceWidget::PointingDeviceWidget(GuiObject* boss, const GUI::Font& font,
int x, int y, Controller& controller)
: ControllerWidget(boss, font, x, y, controller)
{
bool leftport = controller.jack() == Controller::Left;
@ -137,6 +137,6 @@ void PointingDeviceWidget::setValue(DataGridWidget* grayValue, const int index,
{
uInt8 grayCode = getGrayCodeTable(index, direction);
// * 8 = a nasty hack, because the DataGridWidget does not support 2 digit binary output
// FIXME * 8 = a nasty hack, because the DataGridWidget does not support 2 digit binary output
grayValue->setList(0, (grayCode & 0b01) + (grayCode & 0b10) * 8);
}
}

View File

@ -25,43 +25,42 @@ class DataGridWidget;
class PointingDeviceWidget : public ControllerWidget
{
public:
PointingDeviceWidget(GuiObject* boss, const GUI::Font& font, int x, int y,
Controller& controller);
public:
PointingDeviceWidget(GuiObject* boss, const GUI::Font& font, int x, int y,
Controller& controller);
virtual ~PointingDeviceWidget() = default;
virtual ~PointingDeviceWidget() = default;
private:
enum
{
kTBLeft = 'TWlf',
kTBRight = 'TWrt',
kTBUp = 'TWup',
kTBDown = 'TWdn',
kTBFire = 'TWfr'
};
ButtonWidget *myGrayLeft, *myGrayRight;
DataGridWidget* myGrayValueH;
ButtonWidget *myGrayUp, *myGrayDown;
DataGridWidget* myGrayValueV;
CheckboxWidget* myFire;
private:
enum {
kTBLeft = 'TWlf',
kTBRight = 'TWrt',
kTBUp = 'TWup',
kTBDown = 'TWdn',
kTBFire = 'TWfr'
};
ButtonWidget *myGrayLeft, *myGrayRight;
DataGridWidget* myGrayValueH;
ButtonWidget *myGrayUp, *myGrayDown;
DataGridWidget* myGrayValueV;
CheckboxWidget* myFire;
private:
virtual uInt8 getGrayCodeTable(const int index, const int direction) = 0;
private:
virtual uInt8 getGrayCodeTable(const int index, const int direction) = 0;
void loadConfig() override;
void handleCommand(CommandSender* sender, int cmd, int data, int id) override;
void loadConfig() override;
void handleCommand(CommandSender* sender, int cmd, int data, int id) override;
void setGrayCodeH();
void setGrayCodeV();
void setValue(DataGridWidget* greyValue, const int index, const int direction);
void setGrayCodeH();
void setGrayCodeV();
void setValue(DataGridWidget* greyValue, const int index, const int direction);
// Following constructors and assignment operators not supported
PointingDeviceWidget() = delete;
PointingDeviceWidget(const PointingDeviceWidget&) = delete;
PointingDeviceWidget(PointingDeviceWidget&&) = delete;
PointingDeviceWidget& operator=(const PointingDeviceWidget&) = delete;
PointingDeviceWidget& operator=(PointingDeviceWidget&&) = delete;
// Following constructors and assignment operators not supported
PointingDeviceWidget() = delete;
PointingDeviceWidget(const PointingDeviceWidget&) = delete;
PointingDeviceWidget(PointingDeviceWidget&&) = delete;
PointingDeviceWidget& operator=(const PointingDeviceWidget&) = delete;
PointingDeviceWidget& operator=(PointingDeviceWidget&&) = delete;
};
#endif
#endif

View File

@ -17,15 +17,14 @@
#include "TrakBallWidget.hxx"
TrakBallWidget::TrakBallWidget(GuiObject* boss, const GUI::Font& font, int x, int y,
Controller& controller)
TrakBallWidget::TrakBallWidget(GuiObject* boss, const GUI::Font& font,
int x, int y, Controller& controller)
: PointingDeviceWidget(boss, font, x, y, controller)
{}
{
}
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
uInt8 TrakBallWidget::getGrayCodeTable(const int index, const int direction)
{
return myGrayCodeTable[(index & 0b1) + direction * 2];
}

View File

@ -23,23 +23,23 @@
class TrakBallWidget : public PointingDeviceWidget
{
public:
TrakBallWidget(GuiObject* boss, const GUI::Font& font, int x, int y,
Controller& controller);
public:
TrakBallWidget(GuiObject* boss, const GUI::Font& font, int x, int y,
Controller& controller);
virtual ~TrakBallWidget() = default;
virtual ~TrakBallWidget() = default;
private:
uInt8 myGrayCodeTable[4] = { 0b00, 0b10, 0b01, 0b11 };
private:
uInt8 myGrayCodeTable[4] = { 0b00, 0b10, 0b01, 0b11 };
uInt8 getGrayCodeTable(const int index, const int direction);
uInt8 getGrayCodeTable(const int index, const int direction) override;
// Following constructors and assignment operators not supported
TrakBallWidget() = delete;
TrakBallWidget(const TrakBallWidget&) = delete;
TrakBallWidget(TrakBallWidget&&) = delete;
TrakBallWidget& operator=(const TrakBallWidget&) = delete;
TrakBallWidget& operator=(TrakBallWidget&&) = delete;
// Following constructors and assignment operators not supported
TrakBallWidget() = delete;
TrakBallWidget(const TrakBallWidget&) = delete;
TrakBallWidget(TrakBallWidget&&) = delete;
TrakBallWidget& operator=(const TrakBallWidget&) = delete;
TrakBallWidget& operator=(TrakBallWidget&&) = delete;
};
#endif
#endif

View File

@ -240,6 +240,8 @@
<ClCompile Include="..\common\tv_filters\AtariNTSC.cxx" />
<ClCompile Include="..\common\tv_filters\NTSCFilter.cxx" />
<ClCompile Include="..\common\ZipHandler.cxx" />
<ClCompile Include="..\debugger\gui\AmigaMouseWidget.cxx" />
<ClCompile Include="..\debugger\gui\AtariMouseWidget.cxx" />
<ClCompile Include="..\debugger\gui\AtariVoxWidget.cxx" />
<ClCompile Include="..\debugger\gui\BoosterWidget.cxx" />
<ClCompile Include="..\debugger\gui\Cart0840Widget.cxx" />
@ -286,13 +288,16 @@
<ClCompile Include="..\debugger\gui\CartX07Widget.cxx" />
<ClCompile Include="..\debugger\gui\DelayQueueWidget.cxx" />
<ClCompile Include="..\debugger\gui\DrivingWidget.cxx" />
<ClCompile Include="..\debugger\gui\FlashWidget.cxx" />
<ClCompile Include="..\debugger\gui\GenesisWidget.cxx" />
<ClCompile Include="..\debugger\gui\JoystickWidget.cxx" />
<ClCompile Include="..\debugger\gui\KeyboardWidget.cxx" />
<ClCompile Include="..\debugger\gui\PaddleWidget.cxx" />
<ClCompile Include="..\debugger\gui\PointingDeviceWidget.cxx" />
<ClCompile Include="..\debugger\gui\RiotRamWidget.cxx" />
<ClCompile Include="..\debugger\gui\RomListSettings.cxx" />
<ClCompile Include="..\debugger\gui\SaveKeyWidget.cxx" />
<ClCompile Include="..\debugger\gui\TrakBallWidget.cxx" />
<ClCompile Include="..\emucore\Cart3EPlus.cxx" />
<ClCompile Include="..\emucore\Cart4KSC.cxx" />
<ClCompile Include="..\emucore\CartBF.cxx" />
@ -331,9 +336,6 @@
<ClCompile Include="..\gui\JoystickDialog.cxx" />
<ClCompile Include="..\gui\LoggerDialog.cxx" />
<ClCompile Include="..\gui\SnapshotDialog.cxx" />
<ClCompile Include="AmigaMouseWidget.cxx" />
<ClCompile Include="AtariMouseWidget.cxx" />
<ClCompile Include="FlashWidget.cxx" />
<ClCompile Include="FSNodeWINDOWS.cxx" />
<ClCompile Include="OSystemWINDOWS.cxx" />
<ClCompile Include="..\common\PNGLibrary.cxx" />
@ -492,9 +494,6 @@
<ClCompile Include="..\libpng\pngwrite.c" />
<ClCompile Include="..\libpng\pngwtran.c" />
<ClCompile Include="..\libpng\pngwutil.c" />
<ClCompile Include="StateList.cxx" />
<ClCompile Include="PointingDeviceWidget.cxx" />
<ClCompile Include="TrakBallWidget.cxx" />
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\common\Base.hxx" />
@ -515,6 +514,8 @@
<ClInclude Include="..\common\Variant.hxx" />
<ClInclude Include="..\common\Vec.hxx" />
<ClInclude Include="..\common\ZipHandler.hxx" />
<ClInclude Include="..\debugger\gui\AmigaMouseWidget.hxx" />
<ClInclude Include="..\debugger\gui\AtariMouseWidget.hxx" />
<ClInclude Include="..\debugger\gui\AtariVoxWidget.hxx" />
<ClInclude Include="..\debugger\gui\BoosterWidget.hxx" />
<ClInclude Include="..\debugger\gui\Cart0840Widget.hxx" />
@ -563,14 +564,17 @@
<ClInclude Include="..\debugger\gui\ControllerWidget.hxx" />
<ClInclude Include="..\debugger\gui\DelayQueueWidget.hxx" />
<ClInclude Include="..\debugger\gui\DrivingWidget.hxx" />
<ClInclude Include="..\debugger\gui\FlashWidget.hxx" />
<ClInclude Include="..\debugger\gui\GenesisWidget.hxx" />
<ClInclude Include="..\debugger\gui\JoystickWidget.hxx" />
<ClInclude Include="..\debugger\gui\KeyboardWidget.hxx" />
<ClInclude Include="..\debugger\gui\NullControlWidget.hxx" />
<ClInclude Include="..\debugger\gui\PaddleWidget.hxx" />
<ClInclude Include="..\debugger\gui\PointingDeviceWidget.hxx" />
<ClInclude Include="..\debugger\gui\RiotRamWidget.hxx" />
<ClInclude Include="..\debugger\gui\RomListSettings.hxx" />
<ClInclude Include="..\debugger\gui\SaveKeyWidget.hxx" />
<ClInclude Include="..\debugger\gui\TrakBallWidget.hxx" />
<ClInclude Include="..\emucore\AmigaMouse.hxx" />
<ClInclude Include="..\emucore\AtariMouse.hxx" />
<ClInclude Include="..\emucore\BSType.hxx" />
@ -625,9 +629,6 @@
<ClInclude Include="..\libpng\pnginfo.h" />
<ClInclude Include="..\libpng\pnglibconf.h" />
<ClInclude Include="..\libpng\pngstruct.h" />
<ClInclude Include="AmigaMouseWidget.hxx" />
<ClInclude Include="AtariMouseWidget.hxx" />
<ClInclude Include="FlashWidget.hxx" />
<ClInclude Include="FSNodeWINDOWS.hxx" />
<ClInclude Include="HomeFinder.hxx" />
<ClInclude Include="OSystemWINDOWS.hxx" />
@ -792,7 +793,6 @@
<ClInclude Include="..\libpng\pngconf.h" />
<ClInclude Include="..\libpng\pngpriv.h" />
<ClInclude Include="StateList.hxx" />
<ClInclude Include="PointingDeviceWidget.hxx" />
<ClInclude Include="TrakBallWidget.hxx" />
</ItemGroup>
<ItemGroup>

View File

@ -840,22 +840,19 @@
<ClCompile Include="..\common\StateManager.cxx">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="StateList.cxx">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="FlashWidget.cxx">
<ClCompile Include="..\debugger\gui\AmigaMouseWidget.cxx">
<Filter>Source Files\debugger</Filter>
</ClCompile>
<ClCompile Include="AmigaMouseWidget.cxx">
<ClCompile Include="..\debugger\gui\AtariMouseWidget.cxx">
<Filter>Source Files\debugger</Filter>
</ClCompile>
<ClCompile Include="AtariMouseWidget.cxx">
<ClCompile Include="..\debugger\gui\FlashWidget.cxx">
<Filter>Source Files\debugger</Filter>
</ClCompile>
<ClCompile Include="TrakBallWidget.cxx">
<ClCompile Include="..\debugger\gui\PointingDeviceWidget.cxx">
<Filter>Source Files\debugger</Filter>
</ClCompile>
<ClCompile Include="PointingDeviceWidget.cxx">
<ClCompile Include="..\debugger\gui\TrakBallWidget.cxx">
<Filter>Source Files\debugger</Filter>
</ClCompile>
</ItemGroup>
@ -1736,19 +1733,22 @@
<ClInclude Include="StateList.hxx">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="FlashWidget.hxx">
<Filter>Header Files\debugger</Filter>
</ClInclude>
<ClInclude Include="AmigaMouseWidget.hxx">
<Filter>Header Files\debugger</Filter>
</ClInclude>
<ClInclude Include="AtariMouseWidget.hxx">
<Filter>Header Files\debugger</Filter>
</ClInclude>
<ClInclude Include="TrakBallWidget.hxx">
<Filter>Header Files\emucore</Filter>
</ClInclude>
<ClInclude Include="PointingDeviceWidget.hxx">
<ClInclude Include="..\debugger\gui\AmigaMouseWidget.hxx">
<Filter>Header Files\debugger</Filter>
</ClInclude>
<ClInclude Include="..\debugger\gui\AtariMouseWidget.hxx">
<Filter>Header Files\debugger</Filter>
</ClInclude>
<ClInclude Include="..\debugger\gui\FlashWidget.hxx">
<Filter>Header Files\debugger</Filter>
</ClInclude>
<ClInclude Include="..\debugger\gui\PointingDeviceWidget.hxx">
<Filter>Header Files\debugger</Filter>
</ClInclude>
<ClInclude Include="..\debugger\gui\TrakBallWidget.hxx">
<Filter>Header Files\debugger</Filter>
</ClInclude>
</ItemGroup>