diff cagou/plugins/plugin_transfer_android_photo.py @ 491:203755bbe0fe

massive refactoring from camelCase -> snake_case. See backend commit log for more details
author Goffi <goffi@goffi.org>
date Sat, 08 Apr 2023 13:44:32 +0200
parents 3c9ba4a694ef
children
line wrap: on
line diff
--- a/cagou/plugins/plugin_transfer_android_photo.py	Sat Apr 08 13:34:55 2023 +0200
+++ b/cagou/plugins/plugin_transfer_android_photo.py	Sat Apr 08 13:44:32 2023 +0200
@@ -49,13 +49,13 @@
         self.callback = callback
         self.cancel_cb = cancel_cb
         filename = time.strftime("%Y-%m-%d_%H:%M:%S.jpg", time.gmtime())
-        tmp_dir = self.getTmpDir()
+        tmp_dir = self.get_tmp_dir()
         tmp_file = os.path.join(tmp_dir, filename)
         log.debug("Picture will be saved to {}".format(tmp_file))
         camera.take_picture(tmp_file, self.callback)
         # we don't delete the file, as it is nice to keep it locally
 
-    def getTmpDir(self):
+    def get_tmp_dir(self):
         if sys.platform == "android":
             dcim_path = Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_DCIM).getAbsolutePath()
             return dcim_path