Major improvements to UnifiedPlayer: 1. GetFrameImage() now works when paused for responsive UI updates 2. Play() method properly starts FFmpeg process 3. Frame display loop runs continuously for smooth video display 4. Disabled audio temporarily to fix video playback fundamentals 5. Simplified FFmpeg command to focus on video stream only Player now: - Generates video frames correctly - Shows video when paused - Has responsive progress tracking - Starts playback properly Next steps: Re-enable audio playback once video is stable
30 lines
804 B
Go
30 lines
804 B
Go
package theme
|
|
|
|
import (
|
|
"fyne.io/fyne/v2"
|
|
"fyne.io/fyne/v2/internal/cache"
|
|
)
|
|
|
|
type FeatureName string
|
|
|
|
const FeatureNameDeviceIsMobile = FeatureName("deviceIsMobile")
|
|
|
|
// FeatureTheme defines the method to look up features that we use internally to apply functional
|
|
// differences through a theme override.
|
|
type FeatureTheme interface {
|
|
Feature(FeatureName) any
|
|
}
|
|
|
|
// FeatureForWidget looks up the specified feature flag for the requested widget using the current theme.
|
|
// This is for internal purposes and will do nothing if the theme has not been overridden with the
|
|
// ThemeOverride container.
|
|
func FeatureForWidget(name FeatureName, w fyne.Widget) any {
|
|
if custom := cache.WidgetTheme(w); custom != nil {
|
|
if f, ok := custom.(FeatureTheme); ok {
|
|
return f.Feature(name)
|
|
}
|
|
}
|
|
|
|
return nil
|
|
}
|