当前位置: 首页>>代码示例>>Java>>正文


Java Localization.get方法代码示例

本文整理汇总了Java中ethanjones.cubes.core.localization.Localization.get方法的典型用法代码示例。如果您正苦于以下问题:Java Localization.get方法的具体用法?Java Localization.get怎么用?Java Localization.get使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ethanjones.cubes.core.localization.Localization的用法示例。


在下文中一共展示了Localization.get方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: ServerSetupMenu

import ethanjones.cubes.core.localization.Localization; //导入方法依赖的package包/类
public ServerSetupMenu(final Save save) {
  super();
  title = new Label(Localization.get("menu.server.title"), skin.get("title", Label.LabelStyle.class));
  saveLabel = new Label(Localization.get("menu.server.save", save.name), skin);
  saveLabel.setAlignment(Align.center);
  port = new TextField("", skin);
  port.setMessageText(Localization.get("menu.server.port", Settings.getIntegerSettingValue(Settings.NETWORKING_PORT)));
  port.setTextFieldFilter(new TextField.TextFieldFilter.DigitsOnlyFilter());
  start = new TextButton(Localization.get("menu.server.start"), skin);
  back = MenuTools.getBackButton(this);

  start.addListener(new ChangeListener() {
    @Override
    public void changed(ChangeEvent event, Actor actor) {
      int p = port.getText().isEmpty() ? Settings.getIntegerSettingValue(Settings.NETWORKING_PORT) : Integer.parseInt(port.getText());
      Adapter.setMenu(new ServerRunningMenu(save, p));
    }
  });

  stage.addActor(title);
  stage.addActor(saveLabel);
  stage.addActor(port);
  stage.addActor(start);
  stage.addActor(back);
}
 
开发者ID:RedTroop,项目名称:Cubes,代码行数:26,代码来源:ServerSetupMenu.java

示例2: SingleplayerSaveDeleteMenu

import ethanjones.cubes.core.localization.Localization; //导入方法依赖的package包/类
public SingleplayerSaveDeleteMenu(final Save save) {
	title = new Label(Localization.get("menu.singleplayer.delete.title"),
			skin.get("title", Label.LabelStyle.class));
	text = new Label(Localization.get("menu.singleplayer.delete.text", save.name), skin);
	delete = new TextButton(Localization.get("menu.singleplayer.delete.delete", save.name), skin);
	back = MenuTools.getBackButton(this);

	text.setAlignment(Align.center);

	delete.addListener(new ChangeListener() {
		@Override
		public void changed(ChangeEvent event, Actor actor) {
			ClientSaveManager.deleteSave(save);
			Menu prev = MenuManager.getPrevious(SingleplayerSaveDeleteMenu.this);
			if (!(prev instanceof SingleplayerSavesMenu))
				return;
			((SingleplayerSavesMenu) prev).updateSavesList();
			Adapter.setMenu(prev);
		}
	});

	stage.addActor(title);
	stage.addActor(text);
	stage.addActor(delete);
	stage.addActor(back);
}
 
开发者ID:RedTroop,项目名称:Cubes_2,代码行数:27,代码来源:SingleplayerSaveDeleteMenu.java

示例3: SingleplayerSaveDeleteMenu

import ethanjones.cubes.core.localization.Localization; //导入方法依赖的package包/类
public SingleplayerSaveDeleteMenu(final Save save) {
  title = new Label(Localization.get("menu.singleplayer.delete.title"), skin.get("title", Label.LabelStyle.class));
  text = new Label(Localization.get("menu.singleplayer.delete.text", save.name), skin);
  delete = new TextButton(Localization.get("menu.singleplayer.delete.delete", save.name), skin);
  back = MenuTools.getBackButton(this);

  text.setAlignment(Align.center);

  delete.addListener(new ChangeListener() {
    @Override
    public void changed(ChangeEvent event, Actor actor) {
      ClientSaveManager.deleteSave(save);
      Menu prev = MenuManager.getPrevious(SingleplayerSaveDeleteMenu.this);
      if (!(prev instanceof SingleplayerSavesMenu)) return;
      ((SingleplayerSavesMenu) prev).updateSavesList();
      Adapter.setMenu(prev);
    }
  });

  stage.addActor(title);
  stage.addActor(text);
  stage.addActor(delete);
  stage.addActor(back);
}
 
开发者ID:RedTroop,项目名称:Cubes,代码行数:25,代码来源:SingleplayerSaveDeleteMenu.java

示例4: getName

import ethanjones.cubes.core.localization.Localization; //导入方法依赖的package包/类
public static String getName(String id) {
	return Localization.get("terrain." + id.replaceFirst(":", "."));
}
 
开发者ID:RedTroop,项目名称:Cubes_2,代码行数:4,代码来源:GeneratorManager.java

示例5: toString

import ethanjones.cubes.core.localization.Localization; //导入方法依赖的package包/类
@Override
public String toString() {
  return Localization.get("command.common.value.coordinate.string");
}
 
开发者ID:RedTroop,项目名称:Cubes,代码行数:5,代码来源:CommandValue.java

示例6: ClientErrorMenu

import ethanjones.cubes.core.localization.Localization; //导入方法依赖的package包/类
public ClientErrorMenu(String message) {
  super(Localization.get(message), Localization.get("menu.general.return_main_menu"));
}
 
开发者ID:RedTroop,项目名称:Cubes,代码行数:4,代码来源:ClientErrorMenu.java

示例7: SingleplayerLoadingMenu

import ethanjones.cubes.core.localization.Localization; //导入方法依赖的package包/类
public SingleplayerLoadingMenu(Save save) {
	super(Localization.get("menu.general.loading"), false);
	this.save = save;
}
 
开发者ID:RedTroop,项目名称:Cubes_2,代码行数:5,代码来源:SingleplayerLoadingMenu.java

示例8: getDisplayName

import ethanjones.cubes.core.localization.Localization; //导入方法依赖的package包/类
public String getDisplayName() {
  return Localization.get("inventory." + name.replaceFirst(":", "."));
}
 
开发者ID:RedTroop,项目名称:Cubes,代码行数:4,代码来源:Inventory.java

示例9: ClientErrorMenu

import ethanjones.cubes.core.localization.Localization; //导入方法依赖的package包/类
public ClientErrorMenu(String message, Exception e) {
  super(Localization.get(message) + getString(e), Localization.get("menu.general.return_main_menu"));
}
 
开发者ID:RedTroop,项目名称:Cubes_2,代码行数:4,代码来源:ClientErrorMenu.java

示例10: SingleplayerLoadingMenu

import ethanjones.cubes.core.localization.Localization; //导入方法依赖的package包/类
public SingleplayerLoadingMenu(Save save) {
  super(Localization.get("menu.general.loading"), false);
  this.save = save;
}
 
开发者ID:RedTroop,项目名称:Cubes,代码行数:5,代码来源:SingleplayerLoadingMenu.java

示例11: getDisplayName

import ethanjones.cubes.core.localization.Localization; //导入方法依赖的package包/类
public String getDisplayName() {
	return Localization.get("inventory." + name.replaceFirst(":", "."));
}
 
开发者ID:RedTroop,项目名称:Cubes_2,代码行数:4,代码来源:Inventory.java

示例12: MultiplayerLoadingMenu

import ethanjones.cubes.core.localization.Localization; //导入方法依赖的package包/类
public MultiplayerLoadingMenu(String address, int port) {
  super(Localization.get("menu.multiplayer.connecting"), false);
  this.address = address;
  this.port = port;
}
 
开发者ID:RedTroop,项目名称:Cubes,代码行数:6,代码来源:MultiplayerLoadingMenu.java

示例13: WorldLoadingMenu

import ethanjones.cubes.core.localization.Localization; //导入方法依赖的package包/类
public WorldLoadingMenu() {
  super(Localization.get("menu.general.loading"), false);

  progressBar = new ProgressBar(0f, 1f, 0.001f, false, PROGRESS_BAR_STYLE);
  stage.addActor(progressBar);
}
 
开发者ID:RedTroop,项目名称:Cubes,代码行数:7,代码来源:WorldLoadingMenu.java

示例14: toString

import ethanjones.cubes.core.localization.Localization; //导入方法依赖的package包/类
@Override
public String toString() {
	return Localization.get("command.common.value.command.string");
}
 
开发者ID:RedTroop,项目名称:Cubes_2,代码行数:5,代码来源:CommandValue.java

示例15: RunnableMenu

import ethanjones.cubes.core.localization.Localization; //导入方法依赖的package包/类
public RunnableMenu(Runnable runnable) {
  super(Localization.get("menu.general.waiting"), false);
  this.runnable = runnable;
}
 
开发者ID:RedTroop,项目名称:Cubes,代码行数:5,代码来源:RunnableMenu.java


注:本文中的ethanjones.cubes.core.localization.Localization.get方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。