@@ -218,24 +218,18 @@ qx.Class.define("osparc.dashboard.StudyBrowserHeader", {
218218 } ,
219219
220220 __buildLayout : function ( ) {
221+ this . _removeAll ( ) ;
222+
221223 this . getChildControl ( "icon" ) ;
222224 const title = this . getChildControl ( "title" ) ;
223- title . resetCursor ( ) ;
224- title . removeListener ( "tap" , this . __titleTapped , this ) ;
225- this . getChildControl ( "breadcrumbs" ) ;
226- this . getChildControl ( "edit-button" ) . exclude ( ) ;
227- this . resetAccessRights ( ) ;
228- this . resetMyAccessRights ( ) ;
229- const description = this . getChildControl ( "description" ) ;
230- description . resetValue ( ) ;
231- this . getChildControl ( "empty-trash-button" ) . exclude ( ) ;
232-
233225 const currentContext = osparc . store . Store . getInstance ( ) . getStudyBrowserContext ( ) ;
234226 switch ( currentContext ) {
235227 case "studiesAndFolders" : {
236228 const workspaceId = this . getCurrentWorkspaceId ( ) ;
237229 title . setCursor ( "pointer" ) ;
238230 title . addListener ( "tap" , this . __titleTapped , this ) ;
231+ this . getChildControl ( "breadcrumbs" ) ;
232+ this . getChildControl ( "edit-button" ) . exclude ( ) ;
239233 const workspace = osparc . store . Workspaces . getInstance ( ) . getWorkspace ( workspaceId ) ;
240234 if ( workspace ) {
241235 const thumbnail = workspace . getThumbnail ( ) ;
@@ -263,14 +257,14 @@ qx.Class.define("osparc.dashboard.StudyBrowserHeader", {
263257 break ;
264258 case "trash" : {
265259 this . __setIcon ( "@FontAwesome5Solid/trash/20" ) ;
266- const trashDays = osparc . store . StaticInfo . getInstance ( ) . getTrashRetentionDays ( ) ;
267260 title . set ( {
268- value : this . tr ( "Trash:" ) ,
269- cursor : "auto" ,
261+ value : this . tr ( "Trash" )
270262 } ) ;
271- description . set ( {
263+ const trashDays = osparc . store . StaticInfo . getInstance ( ) . getTrashRetentionDays ( ) ;
264+ this . getChildControl ( "description" ) . set ( {
272265 value : this . tr ( `Items in the bin will be permanently deleted after ${ trashDays } days.` )
273266 } ) ;
267+ this . getChildControl ( "empty-trash-button" ) . exclude ( ) ;
274268 break ;
275269 }
276270 }
0 commit comments