// ĠCopyright Ġ 2 0 0 0 - 2 0 1 9 ĠJetBrains Ġs . r . o . ĠUse Ġof Ġthis Ġsource Ġcode Ġis Ġgoverned Ġby Ġthe ĠApache Ġ 2 . 0 Ġlicense Ġthat Ġcan Ġbe Ġfound Ġin Ġthe ĠLICENSE Ġfile . Ċ package Ġcom . intellij . code Insight . int ention . impl . preview Ċ Ċ import Ġcom . intellij . openapi . editor . colors . Editor Colors Manager Ċ import Ġcom . intellij . openapi . project . Project Ċ import Ġcom . intellij . openapi . ui . Loading Decorator Ċ import Ġcom . intellij . ui . Color Util Ċ import Ġcom . intellij . ui . components . panels . Non Opaque Panel Ċ import Ġcom . intellij . ui . components . panels . Opaque Panel Ċ import Ġcom . intellij . util . ui . Async Process Icon Ċ import Ġjava . awt . Border Layout Ċ import Ġjava . awt . Color Ċ import Ġjava . awt . Flow Layout Ċ import Ġjavax . swing . JLabel Ċ import Ġjavax . swing . JPanel Ċ Ċ internal Ġclass ĠInt ention Preview Loading Decorator ( panel : ĠJPanel , Ġproject : ĠProject ) Ġ: ĊĠ ĠLoading Decorator ( panel , Ġproject , Ġ 5 0 0 , Ġfalse , ĠAsync Process Icon (" Int ention Preview Process Loading ")) Ġ{ ĊĠ Ġoverride Ġfun Ġcustomize Loading Layer ( parent : ĠJPanel , Ġtext : ĠJLabel , Ġicon : ĠAsync Process Icon ): ĠNon Opaque Panel Ġ{ ĊĠĠĠ Ġval Ġeditor Background Ġ= ĠEditor Colors Manager . getInstance (). global Scheme . default Background ĊĠĠĠ Ġval Ġicon Non Opaque Panel Ġ= ĠO pa que Panel ( Flow Layout ( Flow Layout . RIGHT , Ġ 2 , Ġ 2 )) ĊĠĠĠĠĠ Ġ. apply Ġ{ ĊĠĠĠĠĠĠĠ Ġadd ( icon , ĠBorderLayout . NORTH ) ĊĠĠĠĠĠĠĠ Ġbackground Ġ= Ġeditor Background ĊĠĠĠĠĠ Ġ} ĊĊĠĠĠ Ġicon . background Ġ= Ġeditor Background . with Alpha ( 0 . 0 ) ĊĠĠĠ Ġicon . is Opaque Ġ= Ġtrue ĊĊĠĠĠ Ġval Ġopaque Panel Ġ= ĠO pa que Panel () ĊĠĠĠ Ġopaque Panel . background Ġ= Ġeditor Background . with Alpha ( 0 . 6 ) ĊĊĠĠĠ Ġval Ġnon Opaque Panel Ġ= ĠNon Opaque Panel ( Border Layout ()) ĊĠĠĠ Ġnon Opaque Panel . add ( icon Non Opaque Panel , ĠBorderLayout . EAST ) ĊĠĠĠ Ġnon Opaque Panel . add ( opaque Panel , ĠBorderLayout . CENTER ) ĊĊĠĠĠ Ġparent . layout Ġ= ĠBorderLayout () ĊĠĠĠ Ġparent . add ( non Opaque Panel ) ĊĊĠĠĠ Ġreturn Ġnon Opaque Panel ĊĠ Ġ} ĊĊĠ Ġfun ĠColor . with Alpha ( alpha : ĠDouble ) Ġ= ĠColor Util . with Alpha ( this , Ġalpha ) Ċ }