Commit 6a25256c authored by Eric Petit's avatar Eric Petit

vout_intf.c: write snapshots on Desktop on BeOS

 beos/*: use B_KEY_DOWN/B_KEY_UP messages instead of KeyDown()/KeyUp()
   so we can have access to the key code and be more reliable (fixes a
   bunch of hotkeys). Fixed snapshots (missing pf_control)
parent ed65a598
...@@ -46,17 +46,10 @@ void E_(CloseVideo) ( vlc_object_t * ); ...@@ -46,17 +46,10 @@ void E_(CloseVideo) ( vlc_object_t * );
/***************************************************************************** /*****************************************************************************
* Module descriptor * Module descriptor
*****************************************************************************/ *****************************************************************************/
static char * ppsz_screenshotformat[] = { "TGA", "PPM", "PNG", "JPEG", "BMP" };
vlc_module_begin(); vlc_module_begin();
set_category( CAT_INTERFACE ); set_category( CAT_INTERFACE );
set_subcategory( SUBCAT_INTERFACE_GENERAL ); set_subcategory( SUBCAT_INTERFACE_GENERAL );
add_bool( "beos-dvdmenus", 0, NULL, _("Use DVD Menus"), "", VLC_TRUE ); add_bool( "beos-dvdmenus", 0, NULL, _("Use DVD Menus"), "", VLC_TRUE );
add_string( "beos-screenshotpath", "/boot/home/", NULL,
_("Screenshot Path"), "", VLC_TRUE );
add_string( "beos-screenshotformat", "PNG", NULL,
_("Screenshot Format"),"", VLC_TRUE );
change_string_list( ppsz_screenshotformat, 0, 0 );
set_description( _("BeOS standard API interface") ); set_description( _("BeOS standard API interface") );
set_capability( "interface", 100 ); set_capability( "interface", 100 );
set_callbacks( E_(OpenIntf), E_(CloseIntf) ); set_callbacks( E_(OpenIntf), E_(CloseIntf) );
......
...@@ -208,7 +208,6 @@ MediaControlView::AttachedToWindow() ...@@ -208,7 +208,6 @@ MediaControlView::AttachedToWindow()
r.bottom += height; r.bottom += height;
// see that our calculated minimal width is not smaller than what // see that our calculated minimal width is not smaller than what
// the menubar can be // the menubar can be
printf("preferred: width: %f, height: %f - width: %f\n", width, height, r.Width());
width -= r.Width(); width -= r.Width();
if (width > 0.0) if (width > 0.0)
r.right += width; r.right += width;
......
This diff is collapsed.
...@@ -117,7 +117,6 @@ class VLCView : public BView ...@@ -117,7 +117,6 @@ class VLCView : public BView
const BMessage* dragMessage); const BMessage* dragMessage);
virtual void Pulse(); virtual void Pulse();
virtual void Draw(BRect updateRect); virtual void Draw(BRect updateRect);
virtual void KeyUp(const char* bytes, int32 numBytes);
private: private:
vout_thread_t *p_vout; vout_thread_t *p_vout;
...@@ -190,20 +189,6 @@ private: ...@@ -190,20 +189,6 @@ private:
void _SetVideoSize(uint32_t mode); void _SetVideoSize(uint32_t mode);
void _SetToSettings(); void _SetToSettings();
void _SaveScreenShot( BBitmap* bitmap,
char* path,
uint32_t translatorID ) const;
static int32 _save_screen_shot( void* cookie );
struct screen_shot_info
{
BBitmap* bitmap;
char* path;
uint32_t translatorID;
int32_t width;
int32_t height;
};
vout_thread_t *p_vout; vout_thread_t *p_vout;
int32_t fTrueWidth; // incomming bitmap size int32_t fTrueWidth; // incomming bitmap size
......
...@@ -270,7 +270,7 @@ int vout_Snapshot( vout_thread_t *p_vout, picture_t *p_pic ) ...@@ -270,7 +270,7 @@ int vout_Snapshot( vout_thread_t *p_vout, picture_t *p_pic )
val.psz_string = 0; val.psz_string = 0;
} }
#ifdef SYS_DARWIN #if defined(SYS_DARWIN) || defined(SYS_BEOS)
if( !val.psz_string && p_vout->p_vlc->psz_homedir ) if( !val.psz_string && p_vout->p_vlc->psz_homedir )
{ {
asprintf( &val.psz_string, "%s/Desktop", asprintf( &val.psz_string, "%s/Desktop",
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment