diff --git a/ruamoko/qwaq/qwaq-proxyview.r b/ruamoko/qwaq/qwaq-proxyview.r index a29b1dedd..e0f2bb469 100644 --- a/ruamoko/qwaq/qwaq-proxyview.r +++ b/ruamoko/qwaq/qwaq-proxyview.r @@ -21,12 +21,16 @@ -setView:(View *) view { int state = [self.view state]; + id context = [self.view context]; + if (state & sfInFocus) { [self.view loseFocus]; - [self.view hide]; } + [self.view hide]; + [self.view setContext:nil]; self.view = view; + [view setContext:context]; if (state & sfDrawn) { [view draw]; } diff --git a/ruamoko/qwaq/qwaq-view.h b/ruamoko/qwaq/qwaq-view.h index 76b3607d5..b2c98c88b 100644 --- a/ruamoko/qwaq/qwaq-view.h +++ b/ruamoko/qwaq/qwaq-view.h @@ -59,6 +59,7 @@ enum { -(int) options; -(int) state; +-(id)context; -setContext: (id) context; -draw; -hide; diff --git a/ruamoko/qwaq/qwaq-view.r b/ruamoko/qwaq/qwaq-view.r index 7a5cd01f0..707fd056e 100644 --- a/ruamoko/qwaq/qwaq-view.r +++ b/ruamoko/qwaq/qwaq-view.r @@ -35,7 +35,12 @@ [super dealloc]; } -- setContext: (id) context +-(id)context +{ + return textContext; +} + +-setContext: (id) context { textContext = context; return self;