{"id":20217400,"url":"https://github.com/windowsnt/rgf","last_synced_at":"2025-08-18T17:04:59.118Z","repository":{"id":80700406,"uuid":"188810071","full_name":"WindowsNT/rgf","owner":"WindowsNT","description":"A single header open/save dialog box with local/googledrive/onedrive WinRT interface for Windows","archived":false,"fork":false,"pushed_at":"2019-06-02T08:23:42.000Z","size":535,"stargazers_count":17,"open_issues_count":0,"forks_count":4,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-10T16:06:45.592Z","etag":null,"topics":["cpp","drive","dropbox","googledrive","onedrive","rest","uwp","win32"],"latest_commit_sha":null,"homepage":null,"language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/WindowsNT.png","metadata":{"files":{"readme":"Readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-05-27T09:08:47.000Z","updated_at":"2025-02-19T17:23:14.000Z","dependencies_parsed_at":null,"dependency_job_id":"a50db59f-fe78-4ffc-be04-b2beeb124034","html_url":"https://github.com/WindowsNT/rgf","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/WindowsNT/rgf","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WindowsNT%2Frgf","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WindowsNT%2Frgf/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WindowsNT%2Frgf/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WindowsNT%2Frgf/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/WindowsNT","download_url":"https://codeload.github.com/WindowsNT/rgf/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WindowsNT%2Frgf/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":271027688,"owners_count":24687081,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-18T02:00:08.743Z","response_time":89,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cpp","drive","dropbox","googledrive","onedrive","rest","uwp","win32"],"created_at":"2024-11-14T06:33:56.783Z","updated_at":"2025-08-18T17:04:58.986Z","avatar_url":"https://github.com/WindowsNT.png","language":"C++","readme":"# RGF Library\n\nA way for normal Win32 applications to have Load/Save features from either a local file or GoogleDrive/OneDrive/DropBox.\n\n\n![WUP](https://raw.githubusercontent.com/WindowsNT/rgf/master/1.jpg)\n![Plain](https://raw.githubusercontent.com/WindowsNT/rgf/master/2.jpg)\n\n\n## Usage:\n\n```C++\n#include \"rgf1.h\" // Generic library, containing REST, GOD, ystring, RKEY, AX etc\n#include \"rgf2.h\" // For UWP interface (Windows 10 Build 1903+)\n#include \"rgf3.h\" // For Common dialog interface\n```\n\nIf using the common dialog interface, add also rgf.rc/resource.h to your project.\n\nIf using the UWP interface, add 1.manifest to your project.\n\n\n## Configuring the library with your client/secret for googledrive/onedrive/dropbox and access/refresh tokens if you have them:\n\n```C++\nRGB::RGBF s;\ns.google.tokens.resize(3);\ns.google.id = \"...\";\ns.google.secret = \"...\";\ns.google.tokens[0] = \"... access token ...\";\ns.google.tokens[1] = \"... refresh token ...\";\n// Same for s.one and s.db\t\n```\n\nIf you do not pass an access token, the user will be asked to login. By default, this is done in an external browser (your default), but \nyou can change the function \"RunUrl\" to use my own AX interface which opens an IWebBrowser control. Note that IWebBrowser2 might be incompatible\nwith the latest HTML features, so it is recommended to use the default external browser.\n\nYour redirect URL is listening at port 9932 by default.\n\n\n\n## Opening\n\n```C++\nRGB::RGBF s;\nstd::vector\u003cchar\u003e r;\ns.read = \u0026r;\nHRESULT rv = RGF::Open(s); // Uses the UWP Interface\nHRESULT rv = RGF::Open2(s); // Uses the old Interface\n```\n\nOn success (rv == S_*) the passed vector is filled with the data of the opened file, whether it is a local file or a remote file.\n\n\n## Saving\n```C++\nRGF::RGBF s;\ns.d = d.data();\ns.sz = (DWORD)d.size();\ns.resultFile = L\"r:\\\\1.dat\"; // for default local saving\ns.DefExt = L\"dat\"; // added automatically to remote files as well\nHRESULT rv = RGF::Save(s); // Uses the UWP Interface\nHRESULT rv = RGF::Save2(s); // Uses the old Interface\n```\n\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwindowsnt%2Frgf","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwindowsnt%2Frgf","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwindowsnt%2Frgf/lists"}