parent
10a1140d49
commit
372b3c7af6
2 changed files with 5 additions and 12 deletions
|
@ -591,17 +591,6 @@ impl AgentPanel {
|
|||
None
|
||||
};
|
||||
|
||||
// Wait for the Gemini/Native feature flag to be available.
|
||||
let client = workspace.read_with(cx, |workspace, _| workspace.client().clone())?;
|
||||
if !client.status().borrow().is_signed_out() {
|
||||
cx.update(|_, cx| {
|
||||
cx.wait_for_flag_or_timeout::<feature_flags::GeminiAndNativeFeatureFlag>(
|
||||
Duration::from_secs(2),
|
||||
)
|
||||
})?
|
||||
.await;
|
||||
}
|
||||
|
||||
let panel = workspace.update_in(cx, |workspace, window, cx| {
|
||||
let panel = cx.new(|cx| {
|
||||
Self::new(
|
||||
|
|
|
@ -98,6 +98,10 @@ impl FeatureFlag for GeminiAndNativeFeatureFlag {
|
|||
// integration too, and we'd like to turn Gemini/Native on in new builds
|
||||
// without enabling Claude Code in old builds.
|
||||
const NAME: &'static str = "gemini-and-native";
|
||||
|
||||
fn enabled_for_all() -> bool {
|
||||
true
|
||||
}
|
||||
}
|
||||
|
||||
pub struct ClaudeCodeFeatureFlag;
|
||||
|
@ -201,7 +205,7 @@ impl FeatureFlagAppExt for App {
|
|||
fn has_flag<T: FeatureFlag>(&self) -> bool {
|
||||
self.try_global::<FeatureFlags>()
|
||||
.map(|flags| flags.has_flag::<T>())
|
||||
.unwrap_or(false)
|
||||
.unwrap_or(T::enabled_for_all())
|
||||
}
|
||||
|
||||
fn is_staff(&self) -> bool {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue