{"id":27,"date":"2016-06-12T11:40:05","date_gmt":"2016-06-12T11:40:05","guid":{"rendered":"https:\/\/blogs.scummvm.org\/tkachov\/?p=27"},"modified":"2022-05-24T11:41:06","modified_gmt":"2022-05-24T11:41:06","slug":"gsoc-the-gui-week","status":"publish","type":"post","link":"https:\/\/blogs.scummvm.org\/tkachov\/2016\/06\/12\/gsoc-the-gui-week\/","title":{"rendered":"GSoC: The GUI Week"},"content":{"rendered":"<p><img decoding=\"async\" class=\"aligncenter\" src=\"https:\/\/blogs.scummvm.org\/tkachov\/wp-content\/uploads\/sites\/60\/2022\/05\/tab.png\" \/><\/p>\n<p>So, this week\u00a0I worked on\u00a0the GUI mostly. That Cloud Options tab is\u00a0almost fully functional\u00a0\u2014 we\u00a0want to\u00a0modify Connection Wizard a\u00a0little bit, so\u00a0it\u00a0helps users enter the code (which is\u00a0quite long, about 40\u00a0characters). Apart from that everything in\u00a0the tab works as\u00a0it\u00a0should, so\u00a0you can easily switch between your connected storages, see how much place your saves occupied on\u00a0your cloud drive and when the last successful saves sync was. The Connection Wizard works too, yet, as\u00a0I\u00a0mentioned, it\u00a0won\u2019t notify you of\u00a0typos. We\u2019re working on\u00a0corresponding scummvm.org URLs, and these work quite fine.<\/p>\n<p>I\u2019ve also added Google Drive support this week. As\u00a0Google Drive uses file ids instead of\u00a0paths, that wasn\u2019t a\u00a0very pleasant adventure. I\u00a0mean, imagine you want to\u00a0download a\u00a0file knowing a\u00a0path to\u00a0it. However, you can\u2019t just ask to\u00a0find that file because there are no\u00a0paths in\u00a0Google Drive. So, you have to\u00a0divide the path by\u00a0separators, start from the Google Drive root folder and implement path traversal by\u00a0listing the directory, finding a\u00a0corresponding subdirectory and repeating these steps. And, as\u00a0there are no\u00a0paths in\u00a0Google Drive, there could be\u00a0files with the same name! So, there could be\u00a0two ScummVM folders or\u00a0three Saves folders or\u00a0five soltys.000\u00a0files. Well, I\u00a0just use the first one\u2019s id, so\u00a0if\u00a0you\u2019d try to\u00a0mess up\u00a0with the Google Drive\u2019s ScummVM folder\u00a0\u2014 you\u2019d succeed. Also, as\u00a0we\u00a0wanted to\u00a0give more freedom to\u00a0the users, we\u00a0had to\u00a0ask for the whole Google Drive access, because application data folders are completely hidden from users. ScummVM only creates its own folder in\u00a0the Google Drive root directory, so\u00a0fear not!<\/p>\n<p>Finally, I\u00a0worked on\u00a0the progress dialog for the save\/load manager. During the saves sync some slots could be\u00a0unavailable because they are being downloaded. You\u2019d see the following dialog in\u00a0this case:<\/p>\n<p><img decoding=\"async\" class=\"aligncenter\" src=\"https:\/\/blogs.scummvm.org\/tkachov\/wp-content\/uploads\/sites\/60\/2022\/05\/load.png\" \/><\/p>\n<p>Most engines use the common pattern for their save files, so\u00a0I called these engines \u00absimple\u00bb. If\u00a0it\u2019s \u00absimple\u00bb, you can press that \u00abRun in\u00a0background\u00bb button and you\u2019d see all the slots. Some of\u00a0them would be\u00a0\u00ablocked\u00bb and would lack the thumbnail, but all the others would be\u00a0easily available to\u00a0save or\u00a0load. Unfortunately, there are also \u00abcomplex\u00bb engines. I\u00a0was unable to\u00a0implement that \u00ablocked\u00bb slots feature for these because of\u00a0their complex nature, so\u00a0\u00abRun in\u00a0background\u00bb would be\u00a0unavailable. You would have to\u00a0wait until all saves are downloaded, and only then save\/load feature would be\u00a0available. You can always hit the \u00abCancel\u00bb button, but that could leave the currently downloading file damaged, so\u00a0use it\u00a0on\u00a0your own risk =)<\/p>\n<p>I\u2019ll have to\u00a0pass my\u00a0exams the next week, so\u00a0I already started working less. The next week plan is\u00a0to\u00a0upgrade that Connection Wizard dialog and start working on\u00a0the local webserver feature. (Yeah, I\u00a0don\u2019t want you to\u00a0enter that code when ScummVM could do\u00a0it\u00a0for you instead.)<\/p>\n","protected":false},"excerpt":{"rendered":"<p>So, this week\u00a0I worked on\u00a0the GUI mostly. That Cloud Options tab is\u00a0almost fully functional\u00a0\u2014 we\u00a0want to\u00a0modify Connection Wizard a\u00a0little bit, so\u00a0it\u00a0helps users enter the code (which is\u00a0quite long, about 40\u00a0characters). Apart from that everything in\u00a0the tab works as\u00a0it\u00a0should, so\u00a0you can easily switch between your connected storages, see how much place your saves occupied on\u00a0your cloud [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-27","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/blogs.scummvm.org\/tkachov\/wp-json\/wp\/v2\/posts\/27","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blogs.scummvm.org\/tkachov\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blogs.scummvm.org\/tkachov\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blogs.scummvm.org\/tkachov\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blogs.scummvm.org\/tkachov\/wp-json\/wp\/v2\/comments?post=27"}],"version-history":[{"count":1,"href":"https:\/\/blogs.scummvm.org\/tkachov\/wp-json\/wp\/v2\/posts\/27\/revisions"}],"predecessor-version":[{"id":30,"href":"https:\/\/blogs.scummvm.org\/tkachov\/wp-json\/wp\/v2\/posts\/27\/revisions\/30"}],"wp:attachment":[{"href":"https:\/\/blogs.scummvm.org\/tkachov\/wp-json\/wp\/v2\/media?parent=27"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blogs.scummvm.org\/tkachov\/wp-json\/wp\/v2\/categories?post=27"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blogs.scummvm.org\/tkachov\/wp-json\/wp\/v2\/tags?post=27"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}