refactor: rebuild desktop client with Slint

This commit is contained in:
dijunkun
2026-07-21 16:38:51 +08:00
parent eeb6a2a1ae
commit 59f77c2820
79 changed files with 7373 additions and 1009 deletions
+6 -5
View File
@@ -7,8 +7,6 @@
#ifndef _THUMBNAIL_H_
#define _THUMBNAIL_H_
#include <SDL3/SDL.h>
#include <filesystem>
#include <map>
#include <unordered_map>
@@ -19,7 +17,7 @@ namespace crossdesk {
class Thumbnail {
public:
struct RecentConnection {
SDL_Texture* texture = nullptr;
std::filesystem::path image_path;
std::string remote_id;
std::string remote_host_name;
std::string password;
@@ -41,11 +39,14 @@ class Thumbnail {
const std::string& password);
int LoadThumbnail(
SDL_Renderer* renderer,
std::vector<std::pair<std::string, Thumbnail::RecentConnection>>&
recent_connections,
int* width, int* height);
bool DecodeImage(const std::filesystem::path& image_path,
std::vector<unsigned char>* rgba, int* width,
int* height) const;
int DeleteThumbnail(const std::string& filename_keyword);
int DeleteAllFilesInDirectory();
@@ -88,4 +89,4 @@ class Thumbnail {
unsigned char decryptedtext_[64];
};
} // namespace crossdesk
#endif
#endif