[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kopete-devel
Subject:    Re: [kopete-devel] Adding Custom Questions to Chatwindow (was:
From:       Michael Zanetti <michael_zanetti () gmx ! net>
Date:       2009-10-04 13:59:50
Message-ID: 200910041559.55266.michael_zanetti () gmx ! net
[Download RAW message or body]

[Attachment #2 (multipart/signed)]


On Wednesday 30 September 2009 00:15:40 Olivier Goffart wrote:
> Le Tuesday 29 September 2009, Michael Zanetti a écrit :

> > AFAICS we would need the following changes to make that possible:
> > - Introduce a new MessageType "CustomQuestion" or something like that.
> 
> Internal message type should work.

Do you mean the existing MessageDirection::Internal or a newly defined 
MessageType::TypeInternal ?

It seems both would be possible. So perhaps it would be better to stick with 
MessageDirection::Internal, right?

> 
> > - Extend Kopete::Message to be able to transport button names
> 
> Some special HTML tag with given class could do the job.
> 

I'm having trouble with this one. All tags like <input>, <button> etc are 
discarded when calling msg.setHtmlBody().

Any hints how to inject something like <input type=\"button\" id=\"foo\" 
value=\"bar\">?

> > - Make ChatWindowPart and KopeteChatWindowStyle capable to display those
> > questions (including reading Theme files etc.)
> 
> Indeed, buttons should be stylable. (CSS should help)
> 
> > - emit a signal containing the Message::id() and the selected answer from
> >  the ChatWindowPart through the current ChatSession and connect it to the
> >  plugins slot
> 
> Yes, thats the most important missing part.
> 
Yep... I think no problems here...

> > A plugin could then create an incoming message of Type CustomQuestion and
> > custom buttons (Yes/No or End/Refresh) and handle the result in a slot.
> >
> > Would this be possible to realize or am I missing something? And would
> > such a mechanism be desired/accepted in kopete? I think I could implement
> > this with some little help/feedback from people deeper involved into
> > kopete's development.
> 
> I think this is a great idea and that you should do it.
> Having interaction dirrectly on the chatwindow is probably better than
>  popup for many things.
> 

Thanks,
Michael

["signature.asc" (application/pgp-signature)]

_______________________________________________
kopete-devel mailing list
kopete-devel@kde.org
https://mail.kde.org/mailman/listinfo/kopete-devel


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic