From 3e1867b579abac7f9091f5ff5ea51cccc58bb1ea Mon Sep 17 00:00:00 2001 From: Dave Patrick Caberto Date: Sun, 25 Feb 2024 08:47:24 +0800 Subject: [PATCH] refactor: use better PersistMode enum names --- src/recording.rs | 2 +- src/screencast_session/types.rs | 9 ++++++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/src/recording.rs b/src/recording.rs index 360cfa41..acfc3f65 100644 --- a/src/recording.rs +++ b/src/recording.rs @@ -176,7 +176,7 @@ impl Recording { }, *IS_EXPERIMENTAL_MODE, Some(&restore_token), - PersistMode::ExplicitlyRevoked, + PersistMode::Persistent, parent, ) .await diff --git a/src/screencast_session/types.rs b/src/screencast_session/types.rs index 642b2ca6..97c8d3d1 100644 --- a/src/screencast_session/types.rs +++ b/src/screencast_session/types.rs @@ -26,9 +26,12 @@ bitflags! { #[derive(Debug, Copy, Clone, PartialEq, Eq)] #[repr(u32)] pub enum PersistMode { - DoNot = 0, - Application = 1, - ExplicitlyRevoked = 2, + /// Do not persist. + None = 0, + /// Persist as long as the application is alive. + Transient = 1, + /// Persist until the user revokes this permission. + Persistent = 2, } type StreamVariantType = (u32, VariantDict);