ILIAS  trunk Revision v11.0_alpha-1749-g1a06bdef097
All Data Structures Namespaces Files Functions Variables Enumerations Enumerator Modules Pages
ilHelpMetaBarProvider Class Reference
+ Inheritance diagram for ilHelpMetaBarProvider:
+ Collaboration diagram for ilHelpMetaBarProvider:

Public Member Functions

 getMetaBarItems ()
 
- Public Member Functions inherited from ILIAS\GlobalScreen\Scope\MetaBar\Provider\AbstractStaticMetaBarProvider
 __construct (Container $dic)
 
- Public Member Functions inherited from ILIAS\GlobalScreen\Provider\AbstractProvider
 __construct (protected Container $dic)
 
 getFullyQualifiedClassName ()
 
 getProviderNameForPresentation ()
 
- Public Member Functions inherited from ILIAS\GlobalScreen\Scope\MetaBar\Provider\MetaBarProviderInterface
 getProviderNameForPresentation ()
 

Private Member Functions

 getId ()
 

Additional Inherited Members

- Protected Member Functions inherited from ILIAS\GlobalScreen\Provider\AbstractProvider
 globalScreen ()
 
- Protected Attributes inherited from ILIAS\GlobalScreen\Scope\MetaBar\Provider\AbstractStaticMetaBarProvider
Container $dic
 
IdentificationProviderInterface $if
 
MetaBarItemFactory $meta_bar
 

Detailed Description

Definition at line 25 of file class.ilHelpMetaBarProvider.php.

Member Function Documentation

◆ getId()

ilHelpMetaBarProvider::getId ( )
private

Definition at line 29 of file class.ilHelpMetaBarProvider.php.

Referenced by getMetaBarItems().

30  {
31  return $this->if->identifier('help');
32  }
+ Here is the caller graph for this function:

◆ getMetaBarItems()

ilHelpMetaBarProvider::getMetaBarItems ( )
Returns
isItem[]

Implements ILIAS\GlobalScreen\Scope\MetaBar\Provider\StaticMetaBarProvider.

Definition at line 34 of file class.ilHelpMetaBarProvider.php.

References $c, $DIC, Vendor\Package\$f, $id, getId(), ILIAS\GlobalScreen\Provider\AbstractProvider\globalScreen(), null, ILIAS\GlobalScreen\Scope\MainMenu\Factory\withSymbol(), and ILIAS\GlobalScreen\Scope\Footer\Factory\withTitle().

34  : array
35  {
36  global $DIC;
37 
38  $mb = $this->globalScreen()->metaBar();
39 
40  $f = $DIC->ui()->factory();
41 
42  $title = $DIC->language()->txt("help");
43 
44  if ($this->showHelpTool()) {
45  // position should be 0, see bug #26794
46  $item = $mb->topLinkItem($this->getId())
47  ->addComponentDecorator(static function (ILIAS\UI\Component\Component $c): ?ILIAS\UI\Component\Component {
48  if ($c instanceof BulkyButton || $c instanceof BulkyLink) {
49  return $c->withAdditionalOnLoadCode(static function (string $id): string {
50  return "$('#$id').on('click', function() {
51  $('body').trigger('il-help-toggle-slate');
52  return false;
53  })";
54  });
55  }
56  return null;
57  })
58  ->withSymbol($f->symbol()->glyph()->help())
59  ->withTitle($title)
60  ->withPosition(0);
61 
62  return [$item];
63  }
64 
65  return [];
66  }
Interface Observer Contains several chained tasks and infos about them.
$c
Definition: deliver.php:25
while($session_entry=$r->fetchRow(ilDBConstants::FETCHMODE_ASSOC)) return null
global $DIC
Definition: shib_login.php:22
$id
plugin.php for ilComponentBuildPluginInfoObjectiveTest::testAddPlugins
Definition: plugin.php:23
+ Here is the call graph for this function:

The documentation for this class was generated from the following file: