1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-11-08 14:13:57 +01:00

Round 5 of wx3 changes

FileDialog now complete on Linux.  Needs some fine tuning on
Windows and OSX.
Builds with wx3 and gtk2 or gtk3.
Still more effect work to do.
This commit is contained in:
Leland Lucius
2015-07-14 23:33:53 -05:00
parent 2f760c4bac
commit 9b9c8cc073
43 changed files with 3271 additions and 5352 deletions

View File

@@ -464,7 +464,12 @@ void ContrastDialog::OnExport(wxCommandEvent & WXUNUSED(event))
wxString fName = wxT("contrast.txt");
fName = FileSelector(_("Export Contrast Result As:"),
wxEmptyString, fName, wxT("txt"), wxT("*.txt"), wxFD_SAVE | wxRESIZE_BORDER, this);
wxEmptyString,
fName,
wxT("txt"),
wxT("*.txt"),
wxFD_SAVE | wxRESIZE_BORDER,
this);
if (fName == wxT(""))
return;

View File

@@ -220,7 +220,7 @@ sampleCount EffectReverb::ProcessBlock(float **inBlock, float **outBlock, sample
while (remaining)
{
size_t len = min((size_t) remaining, (size_t) BLOCK);
sampleCount len = wxMin(remaining, BLOCK);
for (int c = 0; c < mNumChans; c++)
{
// Write the input samples to the reverb fifo. Returned value is the address of the
@@ -311,7 +311,7 @@ wxArrayString EffectReverb::GetFactoryPresets()
{
wxArrayString names;
for (int i = 0; i < WXSIZEOF(FactoryPresets); i++)
for (size_t i = 0; i < WXSIZEOF(FactoryPresets); i++)
{
names.Add(wxGetTranslation(FactoryPresets[i].name));
}

View File

@@ -46,13 +46,8 @@
#include "lv2/lv2plug.in/ns/extensions/ui/ui.h"
#if defined(__WXGTK__)
#if wxCHECK_VERSION(3, 0, 0)
#include <gtk/gtk.h>
#include "win_gtk.h"
#else
#include <wx/gtk/win_gtk.h>
#include <gtk/gtk.h>
#endif
#endif
#if defined(__WXMSW__)
@@ -1489,7 +1484,7 @@ bool LV2Effect::BuildFancy()
//wxWindow *mContainer = mParent;
#if defined(__WXGTK__)
// Make sure the parent has a window
if (!GTK_WIDGET(mContainer->m_wxwindow)->window)
if (!gtk_widget_get_window(GTK_WIDGET(mContainer->m_wxwindow)))
{
gtk_widget_realize(GTK_WIDGET(mContainer->m_wxwindow));
}
@@ -1545,7 +1540,6 @@ bool LV2Effect::BuildFancy()
gtk_widget_set_size_request(widget, 1, 1);
gtk_widget_set_size_request(widget, sz.width, sz.height);
#if wxCHECK_VERSION(3, 0, 0)
wxPizza *pizza = WX_PIZZA(mContainer->m_wxwindow);
pizza->put(widget,
0, //gtk_pizza_get_xoffset(pizza),
@@ -1553,16 +1547,6 @@ bool LV2Effect::BuildFancy()
sz.width,
sz.height);
gtk_widget_show_all(GTK_WIDGET(pizza));
#else
GtkPizza *pizza = GTK_PIZZA(mContainer->m_wxwindow);
gtk_pizza_put(pizza,
widget,
0, //gtk_pizza_get_xoffset(pizza),
0, //gtk_pizza_get_yoffset(pizza),
sz.width,
sz.height);
gtk_widget_show_all(GTK_WIDGET(pizza));
#endif
si->SetMinSize(wxSize(sz.width, sz.height));
#elif defined(__WXMSW__)
HWND widget = (HWND) suil_instance_get_widget(mSuilInstance);