ObsidianDragon - DragonX ImGui Wallet

Full-node GUI wallet for DragonX cryptocurrency.
Built with Dear ImGui, SDL3, and OpenGL3/DX11.

Features:
- Send/receive shielded and transparent transactions
- Autoshield with merged transaction display
- Built-in CPU mining (xmrig)
- Peer management and network monitoring
- Wallet encryption with PIN lock
- QR code generation for receive addresses
- Transaction history with pagination
- Console for direct RPC commands
- Cross-platform (Linux, Windows)
This commit is contained in:
2026-02-26 02:31:52 -06:00
commit 3aee55b49c
306 changed files with 177789 additions and 0 deletions

80
src/rpc/connection.h Normal file
View File

@@ -0,0 +1,80 @@
// DragonX Wallet - ImGui Edition
// Copyright 2024-2026 The Hush Developers
// Released under the GPLv3
#pragma once
#include <string>
namespace dragonx {
namespace rpc {
/**
* @brief Connection configuration
*/
struct ConnectionConfig {
std::string host = "127.0.0.1";
std::string port = "21769";
std::string rpcuser;
std::string rpcpassword;
std::string hush_dir;
std::string proxy; // SOCKS5 proxy for Tor
bool use_embedded = true;
};
/**
* @brief Manages connection to dragonxd
*
* Handles auto-detection of DRAGONX.conf, starting embedded daemon,
* and connection lifecycle.
*/
class Connection {
public:
Connection();
~Connection();
/**
* @brief Auto-detect and load connection config
* @return Config from DRAGONX.conf or defaults
*/
static ConnectionConfig autoDetectConfig();
/**
* @brief Get the default DRAGONX.conf location
*/
static std::string getDefaultConfPath();
/**
* @brief Get the default DragonX data directory
*/
static std::string getDefaultDataDir();
/**
* @brief Parse a DRAGONX.conf file
* @param path Path to conf file
* @return Parsed configuration
*/
static ConnectionConfig parseConfFile(const std::string& path);
/**
* @brief Check if Sapling params exist
*/
static bool verifySaplingParams();
/**
* @brief Get the Sapling params directory
*/
static std::string getSaplingParamsDir();
/**
* @brief Create a default DRAGONX.conf file
* @param path Path to create the file
* @return true if created successfully
*/
static bool createDefaultConfig(const std::string& path);
private:
};
} // namespace rpc
} // namespace dragonx