@@ -70,28 +70,30 @@ qx.Class.define("osparc.support.Conversation", {
7070 control . addListener ( "execute" , ( ) => this . __reloadMessages ( false ) ) ;
7171 this . _add ( control ) ;
7272 break ;
73+ case "add-message" :
74+ control = new osparc . conversation . AddMessage ( ) . set ( {
75+ padding : 10 ,
76+ } ) ;
77+ this . bind ( "conversationId" , control , "conversationId" ) ;
78+ // make it more compact
79+ control . getChildControl ( "comment-field" ) . getChildControl ( "tabs" ) . getChildControl ( "bar" ) . exclude ( ) ;
80+ control . getChildControl ( "comment-field" ) . getChildControl ( "subtitle" ) . exclude ( ) ;
81+ this . _add ( control ) ;
82+ break ;
7383 }
7484 return control || this . base ( arguments , id ) ;
7585 } ,
7686
7787 __buildLayout : function ( ) {
7888 this . getChildControl ( "messages-container" ) ;
79- this . getChildControl ( "load-more-button" ) ;
80-
81- const addMessages = new osparc . conversation . AddMessage ( ) . set ( {
82- padding : 10 ,
83- } ) ;
84- this . bind ( "conversationId" , addMessages , "conversationId" ) ;
85- addMessages . getChildControl ( "comment-field" ) . getChildControl ( "tabs" ) . getChildControl ( "bar" ) . exclude ( ) ;
86- addMessages . getChildControl ( "comment-field" ) . getChildControl ( "subtitle" ) . exclude ( ) ;
89+ const addMessages = this . getChildControl ( "add-message" ) ;
8790 addMessages . addListener ( "messageAdded" , e => {
8891 const data = e . getData ( ) ;
8992 if ( data [ "conversationId" ] ) {
9093 this . setConversationId ( data [ "conversationId" ] ) ;
9194 this . addMessage ( data ) ;
9295 }
9396 } ) ;
94- this . _add ( addMessages ) ;
9597 } ,
9698
9799 __applyConversationId : function ( value ) {
0 commit comments