1//============================================================================
2//
3// SSSS tt lll lll
4// SS SS tt ll ll
5// SS tttttt eeee ll ll aaaa
6// SSSS tt ee ee ll ll aa
7// SS tt eeeeee ll ll aaaaa -- "An Atari 2600 VCS Emulator"
8// SS SS tt ee ll ll aa aa
9// SSSS ttt eeeee llll llll aaaaa
10//
11// Copyright (c) 1995-2019 by Bradford W. Mott, Stephen Anthony
12// and the Stella Team
13//
14// See the file "License.txt" for information on usage and redistribution of
15// this file, and for a DISCLAIMER OF ALL WARRANTIES.
16//============================================================================
17
18#ifndef CARTRIDGEF6SC_WIDGET_HXX
19#define CARTRIDGEF6SC_WIDGET_HXX
20
21class CartridgeF6SC;
22class PopUpWidget;
23
24#include "CartDebugWidget.hxx"
25
26class CartridgeF6SCWidget : public CartDebugWidget
27{
28 public:
29 CartridgeF6SCWidget(GuiObject* boss, const GUI::Font& lfont,
30 const GUI::Font& nfont,
31 int x, int y, int w, int h,
32 CartridgeF6SC& cart);
33 virtual ~CartridgeF6SCWidget() = default;
34
35 private:
36 struct CartState {
37 ByteArray internalram;
38 uInt16 bank;
39 };
40 CartridgeF6SC& myCart;
41 PopUpWidget* myBank;
42 CartState myOldState;
43
44 enum { kBankChanged = 'bkCH' };
45
46 private:
47 void saveOldState() override;
48 void loadConfig() override;
49 void handleCommand(CommandSender* sender, int cmd, int data, int id) override;
50
51 string bankState() override;
52
53 // start of functions for Cartridge RAM tab
54 uInt32 internalRamSize() override;
55 uInt32 internalRamRPort(int start) override;
56 string internalRamDescription() override;
57 const ByteArray& internalRamOld(int start, int count) override;
58 const ByteArray& internalRamCurrent(int start, int count) override;
59 void internalRamSetValue(int addr, uInt8 value) override;
60 uInt8 internalRamGetValue(int addr) override;
61 string internalRamLabel(int addr) override;
62 // end of functions for Cartridge RAM tab
63
64 // Following constructors and assignment operators not supported
65 CartridgeF6SCWidget() = delete;
66 CartridgeF6SCWidget(const CartridgeF6SCWidget&) = delete;
67 CartridgeF6SCWidget(CartridgeF6SCWidget&&) = delete;
68 CartridgeF6SCWidget& operator=(const CartridgeF6SCWidget&) = delete;
69 CartridgeF6SCWidget& operator=(CartridgeF6SCWidget&&) = delete;
70};
71
72#endif
73