def get_dropbox_shared_folders(): local_ns = get_dropbox_root_ns() local_path = get_dropbox_path() con = sqlite3.connect(platform.get_dropbox_dbfile("filecache.db")) con.row_factory = sqlite3.Row return [(unicode(row["target_ns"]), os.path.normpath(row["server_path"].replace("%s:" % local_ns, local_path).lower())) for row in con.execute("SELECT * FROM mount_table")]
def get_dropbox_config(key): con = sqlite3.connect(platform.get_dropbox_dbfile("config.db")) return con.execute("SELECT * FROM config WHERE config.key=?", (key,)).fetchone()[1]