Hello,
i am currently writing a class that will be available for desktop, iOS and web.
You can select the target platform for a method in the second tab of the inspector. My problem now is that I want to give my class a paint event that is called via the Draw method. There are some subclasses of this class that use the paint event. However, I cannot specify a target platform for an event definition in the inspector. So I cannot create a cross-platform class, because for DrawiOS and DrawWeb i get the compiler error “Can’t find type with this name.”. Is there a workaround?
[code]Event PaintDesktop(g As Graphics)
Event PaintiOS(g As iOSGraphics)
Event PaintWeb(g As WebGraphics)
Sub DrawDesktop(g As Graphics)
RaiseEvent PaintDesktop(g)
End Sub
Sub DrawiOS(g As iOSGraphics)
RaiseEvent PaintiOS(g)
End Sub
Sub DrawWeb(g As WebGraphics)
RaiseEvent PaintWeb(g)
End Sub[/code]