本文整理汇总了Java中com.badlogic.gdx.scenes.scene2d.ui.TooltipManager类的典型用法代码示例。如果您正苦于以下问题:Java TooltipManager类的具体用法?Java TooltipManager怎么用?Java TooltipManager使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
TooltipManager类属于com.badlogic.gdx.scenes.scene2d.ui包,在下文中一共展示了TooltipManager类的19个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: HUDSystem
import com.badlogic.gdx.scenes.scene2d.ui.TooltipManager; //导入依赖的package包/类
/**
* Creates a new HUDSystem object
*
* @param batch - the batch that had been being drawn to before this system
* @param commandUI - the command system
* @param level - the level to represent
* @param screen - a rectangle containing the region that is visible on the screen
*/
public HUDSystem(DrawingBatch batch, CommandUISystem commandUI, Level level, Rectangle screen) {
super(6);
this.batch = batch;
this.commandUI = commandUI;
this.level = level;
this.screen = screen;
tooltipManager = new TooltipManager();
tooltipManager.initialTime = 0.00f;
tooltipManager.subsequentTime = tooltipManager.initialTime;
tooltipManager.resetTime = 0.00f;
tooltipManager.hideAll();
messageEntities = new LinkedList<>();
buttons = new ArrayList<>();
}
开发者ID:SergeySave,项目名称:SpaceGame,代码行数:24,代码来源:HUDSystem.java
示例2: setDefaultTooltipManager
import com.badlogic.gdx.scenes.scene2d.ui.TooltipManager; //导入依赖的package包/类
/** Since main tooltip manager instance cannot be changed globally with a regular setter, this method modifies it
* using reflection.
*
* @param tooltipManager will be returned on {@link TooltipManager#getInstance()} calls. */
public static void setDefaultTooltipManager(final TooltipManager tooltipManager) {
try {
// We have to set the app field, as it is validated by the static getter.
Reflection.setFieldValue(ClassReflection.getDeclaredField(TooltipManager.class, "app"), null, Gdx.app);
Reflection.setFieldValue(ClassReflection.getDeclaredField(TooltipManager.class, "instance"), null,
tooltipManager);
} catch (final ReflectionException exception) {
throw new GdxRuntimeException("Unable to set default tooltip manager.", exception);
}
}
开发者ID:gdx-libs,项目名称:gdx-kiwi,代码行数:15,代码来源:Tooltips.java
示例3: setDefaultTooltipManager
import com.badlogic.gdx.scenes.scene2d.ui.TooltipManager; //导入依赖的package包/类
/** Since main tooltip manager instance cannot be changed globally with a regular setter, this method modifies it
* using reflection.
*
* @param tooltipManager will be returned on {@link TooltipManager#getInstance()} calls.
* @throws GdxRuntimeException if unable to change manager. */
public static void setDefaultTooltipManager(final TooltipManager tooltipManager) {
try {
TooltipManager.getInstance();
Reflection.setFieldValue(ClassReflection.getDeclaredField(TooltipManager.class, "instance"), null,
tooltipManager);
} catch (final ReflectionException exception) {
throw new GdxRuntimeException("Unable to set default tooltip manager.", exception);
}
}
开发者ID:czyzby,项目名称:gdx-lml,代码行数:15,代码来源:Tooltips.java
示例4: getNewInstanceOfActor
import com.badlogic.gdx.scenes.scene2d.ui.TooltipManager; //导入依赖的package包/类
@Override
protected Actor getNewInstanceOfActor(final LmlActorBuilder builder) {
final TooltipManager manager = getTooltipManager((TooltipLmlActorBuilder) builder);
final TooltipTable table = TooltipTable.create(getSkin(builder), manager);
tooltip = table.getTooltip();
return table;
}
开发者ID:czyzby,项目名称:gdx-lml,代码行数:8,代码来源:TooltipLmlTag.java
示例5: getTooltipManager
import com.badlogic.gdx.scenes.scene2d.ui.TooltipManager; //导入依赖的package包/类
/** @param builder contains tooltip building data.
* @return an instance of tooltip manager with the ID selected by the builder or default tooltip manager.
* @throws LmlParsingException if parser is strict and the ID is invalid. */
protected TooltipManager getTooltipManager(final TooltipLmlActorBuilder builder) {
TooltipManager manager = getParser().getData().getTooltipManager(builder.getTooltipManager());
if (manager == null) {
getParser().throwErrorIfStrict("Could not find tooltip manager for name: " + builder.getTooltipManager());
manager = TooltipManager.getInstance();
}
return manager;
}
开发者ID:czyzby,项目名称:gdx-lml,代码行数:12,代码来源:TooltipLmlTag.java
示例6: create
import com.badlogic.gdx.scenes.scene2d.ui.TooltipManager; //导入依赖的package包/类
/** @param skin used to construct table.
* @param tooltipManager used to construct tooltip.
* @return a new TooltipTable instance with a fully initiated tooltip accessible with {@link #getTooltip()}
* method. */
public static TooltipTable create(final Skin skin, final TooltipManager tooltipManager) {
final Tooltip<TooltipTable> tooltip = new Tooltip<TooltipTable>(null, tooltipManager);
final TooltipTable content = new TooltipTable(skin, tooltip);
tooltip.setActor(content);
return content;
}
开发者ID:czyzby,项目名称:gdx-lml,代码行数:11,代码来源:TooltipTable.java
示例7: getManager
import com.badlogic.gdx.scenes.scene2d.ui.TooltipManager; //导入依赖的package包/类
public TooltipManager getManager() {
return manager;
}
开发者ID:JoakimRW,项目名称:ExamensArbeteTD,代码行数:4,代码来源:TooltipTable.java
示例8: setManager
import com.badlogic.gdx.scenes.scene2d.ui.TooltipManager; //导入依赖的package包/类
public void setManager(TooltipManager manager) {
this.manager = manager;
}
开发者ID:JoakimRW,项目名称:ExamensArbeteTD,代码行数:4,代码来源:TooltipTable.java
示例9: initDefaults
import com.badlogic.gdx.scenes.scene2d.ui.TooltipManager; //导入依赖的package包/类
private void initDefaults() {
if (Utils.isMac()) System.setProperty("java.awt.headless", "true");
skin.getFont("font").getData().markupEnabled = true;
//copy defaults.json to temp folder if it doesn't exist
FileHandle fileHandle = Gdx.files.local("texturepacker/defaults.json");
if (!fileHandle.exists()) {
Gdx.files.internal("defaults.json").copyTo(fileHandle);
}
ibeamListener = new IbeamListener();
projectData = new ProjectData();
projectData.setMain(this);
projectData.randomizeId();
projectData.setMaxUndos(30);
dialogFactory = new DialogFactory(this);
undoableManager = new UndoableManager(this);
desktopWorker.attachLogListener();
desktopWorker.sizeWindowToFit(800, 800, 50, Gdx.graphics);
desktopWorker.centerWindow(Gdx.graphics);
desktopWorker.setCloseListener(() -> {
dialogFactory.showCloseDialog();
return false;
});
loadingAnimation = new AnimatedDrawable(.05f);
loadingAnimation.addDrawable(skin.getDrawable("loading_0"));
loadingAnimation.addDrawable(skin.getDrawable("loading_1"));
loadingAnimation.addDrawable(skin.getDrawable("loading_2"));
loadingAnimation.addDrawable(skin.getDrawable("loading_3"));
loadingAnimation.addDrawable(skin.getDrawable("loading_4"));
loadingAnimation.addDrawable(skin.getDrawable("loading_5"));
loadingAnimation.addDrawable(skin.getDrawable("loading_6"));
loadingAnimation.addDrawable(skin.getDrawable("loading_7"));
projectData.getAtlasData().clearTempData();
handListener = new HandListener();
tooltipManager = new TooltipManager();
tooltipManager.animations = false;
tooltipManager.initialTime = .4f;
tooltipManager.resetTime = 0.0f;
tooltipManager.subsequentTime = 0.0f;
tooltipManager.hideAll();
tooltipManager.instant();
}
开发者ID:raeleus,项目名称:skin-composer,代码行数:51,代码来源:Main.java
示例10: getTooltipManager
import com.badlogic.gdx.scenes.scene2d.ui.TooltipManager; //导入依赖的package包/类
public TooltipManager getTooltipManager() {
return tooltipManager;
}
开发者ID:raeleus,项目名称:skin-composer,代码行数:4,代码来源:Main.java
示例11: setDefaultTooltipManager
import com.badlogic.gdx.scenes.scene2d.ui.TooltipManager; //导入依赖的package包/类
/** @param tooltipManager will be accessible with the default ID. */
void setDefaultTooltipManager(TooltipManager tooltipManager);
开发者ID:czyzby,项目名称:gdx-lml,代码行数:3,代码来源:LmlData.java
示例12: addTooltipManager
import com.badlogic.gdx.scenes.scene2d.ui.TooltipManager; //导入依赖的package包/类
@Override
public void addTooltipManager(final String name, final TooltipManager tooltipManager) {
tooltipManagers.put(name, tooltipManager);
}
开发者ID:czyzby,项目名称:gdx-lml,代码行数:5,代码来源:DefaultLmlData.java
示例13: setDefaultTooltipManager
import com.badlogic.gdx.scenes.scene2d.ui.TooltipManager; //导入依赖的package包/类
@Override
public void setDefaultTooltipManager(final TooltipManager tooltipManager) {
tooltipManagers.put(DEFAULT_KEY, tooltipManager);
}
开发者ID:czyzby,项目名称:gdx-lml,代码行数:5,代码来源:DefaultLmlData.java
示例14: getTooltipManager
import com.badlogic.gdx.scenes.scene2d.ui.TooltipManager; //导入依赖的package包/类
@Override
public TooltipManager getTooltipManager(final String name) {
return tooltipManagers.get(name, TooltipManager.getInstance());
}
开发者ID:czyzby,项目名称:gdx-lml,代码行数:5,代码来源:DefaultLmlData.java
示例15: getDefaultTooltipManager
import com.badlogic.gdx.scenes.scene2d.ui.TooltipManager; //导入依赖的package包/类
@Override
public TooltipManager getDefaultTooltipManager() {
return tooltipManagers.get(DEFAULT_KEY, TooltipManager.getInstance());
}
开发者ID:czyzby,项目名称:gdx-lml,代码行数:5,代码来源:DefaultLmlData.java
示例16: tooltipManager
import com.badlogic.gdx.scenes.scene2d.ui.TooltipManager; //导入依赖的package包/类
/** @param defaultTooltipManager will be set as the default {@link TooltipManager} instance used when no ID is
* specified.
* @return this for chaining. */
public LmlParserBuilder tooltipManager(final TooltipManager defaultTooltipManager) {
parser.getData().setDefaultTooltipManager(defaultTooltipManager);
return this;
}
开发者ID:czyzby,项目名称:gdx-lml,代码行数:8,代码来源:LmlParserBuilder.java
示例17: addTooltipManager
import com.badlogic.gdx.scenes.scene2d.ui.TooltipManager; //导入依赖的package包/类
/** @param name ID of the registered manager. Implementation might make the ID ignore case, so be careful not to
* repeat IDs for multiple managers.
* @param tooltipManager will be accessible with the chosen ID. */
void addTooltipManager(String name, TooltipManager tooltipManager);
开发者ID:czyzby,项目名称:gdx-lml,代码行数:5,代码来源:LmlData.java
示例18: getTooltipManager
import com.badlogic.gdx.scenes.scene2d.ui.TooltipManager; //导入依赖的package包/类
/** @param name ID of the manager. Might ignore case.
* @return manager associated with the passed ID. */
TooltipManager getTooltipManager(String name);
开发者ID:czyzby,项目名称:gdx-lml,代码行数:4,代码来源:LmlData.java
示例19: getDefaultTooltipManager
import com.badlogic.gdx.scenes.scene2d.ui.TooltipManager; //导入依赖的package包/类
/** @return tooltip manager associated with the default ID. By default, returns LibGDX static tooltip manager
* instance. */
TooltipManager getDefaultTooltipManager();
开发者ID:czyzby,项目名称:gdx-lml,代码行数:4,代码来源:LmlData.java
注:本文中的com.badlogic.gdx.scenes.scene2d.ui.TooltipManager类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论