Annotation of nono/util/sramedit/sramedit.h, revision 1.1.1.1

1.1       root        1: //
                      2: // nono
                      3: // Copyright (C) 2021 nono project
                      4: // Licensed under nono-license.txt
                      5: //
                      6: 
                      7: //
                      8: // X680x0 SRAM.DAT エディタ
                      9: //
                     10: 
                     11: #pragma once
                     12: 
                     13: #include "header.h"
                     14: #include "mystring.h"
                     15: #include <cstdio>
                     16: #include <cstring>
                     17: #include <vector>
                     18: 
                     19: struct sraminfo_t {
                     20:        // このパラメータのオフセット (占有バイト数は持っていない)
                     21:        uint32 offset;
                     22:        // キー名
                     23:        const char *name;
                     24: 
                     25:        // 値の読み出しコールバック。
                     26:        // このパラメータの値を表示用にして返す。
                     27:        // 詳細未定。
                     28:        std::string (*reader)(const sraminfo_t&);
                     29: 
                     30:        // 値の書き込みコールバック。
                     31:        // このパラメータを値 input に更新する。
                     32:        // エラーなら -1、更新の必要がなければ 0、更新すれば更新件数(通常1)を返す。
                     33:        int (*writer)(const sraminfo_t&, const std::string& input);
                     34: 
                     35:        // ヘルプメッセージを返す。
                     36:        const std::string (*help)(const sraminfo_t&);
                     37: };
                     38: 
                     39: extern int debug;
                     40: extern uint8 *sram;
                     41: extern std::vector<sraminfo_t> sraminfo;

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.