LDFLAGS = `wx-config --libs`
-all: test_prg test_dll.so
-
-test_prg: dllwidget.o test_prg.o
- $(CXX) $(LDFLAGS) -o $@ dllwidget.o test_prg.o
+all: test_dll.so
test_dll.so: test_dll.o
$(CXX) $(LDFLAGS) -shared -o $@ $<
$(CXX) -c $(CXXFLAGS) -o $@ $<
clean:
- rm -f *.o *.so test_prg
+ rm -f *.o *.so
"TestWindow",
size=(250, 150))
- # The embedded window is the one exported from the DLL
- print dw.GetEmbeddedWindow().GetClassName()
-
- # This shows that we can give it a child from this side of things.
- # You can also call any wxWindow methods on it too.
- wxStaticText(dw.GetEmbeddedWindow(), -1,
- "Loaded from test_dll...", pos=(10,10))
-
+ if dw.Ok():
+ # The embedded window is the one exported from the DLL
+ print dw.GetEmbeddedWindow().GetClassName()
+
+ # This shows that we can give it a child from this side of things.
+ # You can also call any wxWindow methods on it too.
+ wxStaticText(dw.GetEmbeddedWindow(), -1,
+ "Loaded from test_dll...", pos=(10,10))
+ else:
+ wxStaticText(dw, -1, "ERROR!!!!", pos=(20,20))
sizer = wxBoxSizer(wxVERTICAL)
sizer.Add(wxStaticLine(panel, -1), 0, wxGROW)