bsd lang segv fix, enable bsd lv2, lv2 gui enable fix, proxy/ffmpeg toggle resize...
[goodguy/history.git] / cinelerra-5.1 / cinelerra / keyframegui.C
index d7d297411a7ed868a9519a26a5865bfedb2993e3..a8f99a73c51f2003c35d51dc3112a0bcbe6855a2 100644 (file)
@@ -119,11 +119,14 @@ void KeyFrameThread::update_values()
                        keyframe_data[0].append(new BC_ListBoxItem(hash.get_key(i)));
                        keyframe_data[1].append(new BC_ListBoxItem(hash.get_value(i)));
                }
-               keyframe_data[0].append(new BC_ListBoxItem((char*)"TEXT"));
-               keyframe_data[1].append(new BC_ListBoxItem(text));
-               keyframe_data[0].append(new BC_ListBoxItem((char*)"DATA"));
-               keyframe_data[1].append(new BC_ListBoxItem(data));
-               
+               if( text ) {
+                       keyframe_data[0].append(new BC_ListBoxItem((char*)"TEXT"));
+                       keyframe_data[1].append(new BC_ListBoxItem(text));
+               }
+               if( data ) {
+                       keyframe_data[0].append(new BC_ListBoxItem((char*)"DATA"));
+                       keyframe_data[1].append(new BC_ListBoxItem(data));
+               }
                delete [] text;
                delete [] data;
        }
@@ -146,6 +149,7 @@ void KeyFrameThread::start_window(Plugin *plugin, KeyFrame *keyframe)
                if( !mwindow->edl->tracks->plugin_exists(plugin) ) return;
                this->keyframe = keyframe;
                this->plugin = plugin;
+               this->preset_text[0] = 0;
                plugin->calculate_title(plugin_title, 0);
                sprintf(window_title, _("%s: %s Keyframe"), _(PROGRAM_NAME), plugin_title);
 
@@ -479,7 +483,7 @@ void KeyFrameWindow::create_objects()
 
 
        add_subwindow(title1 = new BC_Title(theme->keyframe_list_x,
-               theme->keyframe_list_y - BC_Title::calculate_h(this, (char*)_("Py"), LARGEFONT) - 
+               theme->keyframe_list_y - BC_Title::calculate_h(this, (char*)"Py", LARGEFONT) - 
                        theme->widget_border, _("Keyframe parameters:"), LARGEFONT));
        add_subwindow(keyframe_list = new KeyFrameList(thread,
                this,
@@ -505,7 +509,7 @@ void KeyFrameWindow::create_objects()
 
 #endif
        add_subwindow(title4 = new BC_Title(theme->presets_list_x, theme->presets_list_y - 
-                       BC_Title::calculate_h(this, (char*)_("Py"), LARGEFONT) - 
+                       BC_Title::calculate_h(this, (char*)"Py", LARGEFONT) - 
                        theme->widget_border, _("Presets:"), LARGEFONT));
        add_subwindow(preset_list = new KeyFramePresetsList(thread, this,
                theme->presets_list_x, theme->presets_list_y,
@@ -796,7 +800,7 @@ KeyFramePresetsSave::KeyFramePresetsSave(KeyFrameThread *thread,
        KeyFrameWindow *window,
        int x,
        int y)
-: BC_GenericButton(x, y, _("Save"))
+: BC_GenericButton(x, y, C_("Save"))
 {
        this->thread = thread;
        this->window = window;