Revision: 155
Author: davidferreira.FZ
Date: Fri Aug 14 18:57:27 2009
Log: [No log message]
http://code.google.com/p/pjmoo-gbf/source/detail?r=155
Added:
/tags/0.9.1/GBF.library.0.9.1.win32.zip
/trunk/doc/imagem
/trunk/doc/imagem/GBFramework_v0.7.png
/trunk/doc/imagem/SpaceShooter_v0.7.jpg
/trunk/projeto/deploy-distro-win32.sh
Modified:
/trunk/doc/uml/GBF/GBF.prj
/trunk/doc/uml/GBF/generation_settings
/trunk/doc/uml/GBF/stereotypes
/trunk/projeto/src/UIItemTexto.cpp
/trunk/projeto/src/UIMenu.cpp
/trunk/projeto/src/WriteManager.cpp
=======================================
--- /dev/null
+++ /tags/0.9.1/GBF.library.0.9.1.win32.zip Fri Aug 14 18:57:27 2009
Binary file, no diff available.
=======================================
--- /dev/null
+++ /trunk/doc/imagem/GBFramework_v0.7.png Fri Aug 14 18:57:27 2009
Binary file, no diff available.
=======================================
--- /dev/null
+++ /trunk/doc/imagem/SpaceShooter_v0.7.jpg Fri Aug 14 18:57:27 2009
Binary file, no diff available.
=======================================
--- /dev/null
+++ /trunk/projeto/deploy-distro-win32.sh Fri Aug 14 18:57:27 2009
@@ -0,0 +1,24 @@
+#!/bin/bash
+export VERSION=0.9.1
+export GBF=/home/desenvolvimento/pjmoo-gbf/
+export WORKSPACE=$GBF/trunk/projeto/
+export WORKVERSION=$GBF/tags/$VERSION
+
+clear
+echo "Criando estrutura de Arquivos..."
+mkdir $WORKVERSION
+mkdir $WORKVERSION/win32
+mkdir $WORKVERSION/win32/lib
+
+
+echo "Copiando: Biblioteca libGBF.a"
+cp -f $WORKSPACE/bin/win32/release/libGBF.a $WORKVERSION/win32/lib/libGBF.a
+
+cd $WORKVERSION/win32
+echo "Empacotando: Para distribuição Zip"
+zip -rq7 $WORKVERSION/GBF.library.$VERSION.win32.zip lib/* -x *SVN*
*svnignore* *.svn*
+
+echo "Removendo arquivos temporarios..."
+rm -r $WORKVERSION/win32
+
+echo "Finalizado"
=======================================
--- /trunk/doc/uml/GBF/GBF.prj Tue Jul 28 15:54:44 2009
+++ /trunk/doc/uml/GBF/GBF.prj Fri Aug 14 18:57:27 2009
@@ -4,7 +4,7 @@
modified_by 28 "david"
artifact_default_description "// GBF - Gamework's Brazilian Framework
-// Copyright (C) 2004-2008 David de Almeida Ferreira
+// Copyright (C) 2004-2009 David de Almeida Ferreira
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Library General Public
=======================================
--- /trunk/doc/uml/GBF/generation_settings Fri Mar 14 20:06:49 2008
+++ /trunk/doc/uml/GBF/generation_settings Fri Aug 14 18:57:27 2009
@@ -223,6 +223,10 @@
" // multiplicity != 1
python_default_operation_definition "${@}${static}${abstract}def
${name}${(}${)}:
${docstring}${body}
+"
+ python_default_initoperation_definition "${@}${static}${abstract}def
${name}${(}${p0}${v0}${)}:
+${docstring}super(${class}, ${p0}).__init__()
+${body}
"
python_get "get${Name}"
python_set "set${Name}"
=======================================
--- /trunk/doc/uml/GBF/stereotypes Tue Jul 28 15:54:44 2009
+++ /trunk/doc/uml/GBF/stereotypes Fri Aug 14 18:57:27 2009
@@ -36,6 +36,8 @@
activitynode_stereotypes 0
activityaction_stereotypes 0
activityobject_stereotypes 2 "datastore" "centralBuffer"
+ expansionregion_stereotypes 0
+ activitypartition_stereotypes 0
pin_stereotypes 0
component_stereotypes
7 "build" "component" "entity" "implement" "process" "service" "subsystem"
deploymentnode_stereotypes 2 "cpu" "device"
=======================================
--- /trunk/projeto/src/UIItemTexto.cpp Sat May 17 20:14:54 2008
+++ /trunk/projeto/src/UIItemTexto.cpp Fri Aug 14 18:57:27 2009
@@ -20,7 +20,7 @@
GBF::Kernel::Write::WriteManager * UIItemTexto::wsManager=NULL;
-UIItemTexto::UIItemTexto(const std::string & texto, const std::string &
fonteTexto)
+UIItemTexto::UIItemTexto(const std::string & texto, const std::string &
fonteTexto)
{
this->texto=texto;
this->fonteTexto=fonteTexto;
@@ -33,10 +33,10 @@
wsManager = GBF::Kernel::Write::WriteManager::getInstance();
}
}
-UIItemTexto::~UIItemTexto()
+UIItemTexto::~UIItemTexto()
{
}
-void UIItemTexto::desenhar(int x, int y)
+void UIItemTexto::desenhar(int x, int y)
{
if (isAtivo()){
tempo.processar();
@@ -47,12 +47,11 @@
wsManager->escreverLocalizado(fonteTexto,x,y,texto.c_str());
}
}
-int UIItemTexto::getQuantidadeLetras()
-{
-// return strlen(wsManager->uiTexto->getTexto(fonteTexto).c_str());
+int UIItemTexto::getQuantidadeLetras()
+{
return wsManager->idioma->getTexto(texto).length();
}
-GBF::Dimensao UIItemTexto::getDimensaoLetra()
+GBF::Dimensao UIItemTexto::getDimensaoLetra()
{
return wsManager->getFonte(fonteTexto)->getDimensao();
}
=======================================
--- /trunk/projeto/src/UIMenu.cpp Sat May 17 20:14:54 2008
+++ /trunk/projeto/src/UIMenu.cpp Fri Aug 14 18:57:27 2009
@@ -19,14 +19,14 @@
namespace Menu {
//Construtor
-UIMenu::UIMenu()
+UIMenu::UIMenu()
{
}
//Destrutor
-UIMenu::~UIMenu()
+UIMenu::~UIMenu()
{
}
-void UIMenu::desenhar()
+void UIMenu::desenhar()
{
if (!item.empty()){
GBF::Dimensao dimensao = item[0]->getDimensaoLetra();
@@ -43,16 +43,20 @@
graphicSystem->gfx->retangulo(t.x,t.y,totalHorizontal,totalVertical);
int pontoY=t.y+offsetY;
+ int pontoX=0;
+ int quantidadeLetras = 0;
for (unsigned int i=0; i<item.size(); i++){
if (item[i]!=NULL){
- int dtmp=item[i]->getQuantidadeLetras();
-
item[i]->desenhar(t.x+(meioHorizontal-((dtmp*dimensao.w)/2)),pontoY);
+
//item[i]->desenhar(t.x+(meioHorizontal-((dtmp*dimensao.w)/2)),pontoY);
+ quantidadeLetras = item[i]->getQuantidadeLetras();
+ pontoX = t.x + meioHorizontal -
(quantidadeLetras*dimensao.w)/2;
+ item[i]->desenhar(pontoX,pontoY);
}
pontoY+=espacoVertical;
}
}
}
-bool UIMenu::navegar()
+bool UIMenu::navegar()
{
bool navegou = false;
@@ -68,14 +72,14 @@
return navegou;
}
-void UIMenu::itemAvancar()
+void UIMenu::itemAvancar()
{
itemSelecionado++;
if (itemSelecionado>=int(item.size())){
itemSelecionado=item.size()-1;
}
}
-void UIMenu::itemAnterior()
+void UIMenu::itemAnterior()
{
itemSelecionado--;
if (itemSelecionado<0){
=======================================
--- /trunk/projeto/src/WriteManager.cpp Mon Nov 10 18:41:19 2008
+++ /trunk/projeto/src/WriteManager.cpp Fri Aug 14 18:57:27 2009
@@ -24,7 +24,7 @@
const std::string WriteManager::defaultFont="default";
//Destrutor
-WriteManager::~WriteManager()
+WriteManager::~WriteManager()
{
// UtilLog::subSistema("Removendo WriteSystemManager");
std::map<std::string,FonteBitmap*>::iterator it;
@@ -43,7 +43,7 @@
}
//Retorna uma fonte para manipulação direta
//Obs.: Ideal para casos em que se deseja manipulações avançadas
-FonteBitmap * WriteManager::getFonte(std::string nome)
+FonteBitmap * WriteManager::getFonte(std::string nome)
{
if (objetomap.find(nome)!=objetomap.end()){
return objetomap[nome];
@@ -62,7 +62,7 @@
return instance;
}
//Carrega e adiciona uma fonte (WriteSystemBitmap)
-void WriteManager::carregar(std::string nome, std::string arquivo)
+void WriteManager::carregar(std::string nome, std::string arquivo)
{
std::string fullpath=Kernel::Util::Path::getPath()+arquivo;
@@ -75,7 +75,7 @@
}
}
//Escreve um texto na tela
-void WriteManager::escrever(std::string fonte, int x, int y, const char *
texto, ...)
+void WriteManager::escrever(std::string fonte, int x, int y, const char *
texto, ...)
{
char texto_aux[256];
va_list ap;
@@ -87,7 +87,7 @@
getFonte(fonte)->escrever(texto_aux,x,y);
}
//Escreve um texto na tela usando recursos de Localização (Tradução)
-void WriteManager::escreverLocalizado(const std::string & fonte, int x,
int y, std::string chave, ...)
+void WriteManager::escreverLocalizado(const std::string & fonte, int x,
int y, std::string chave, ...)
{
char textoFormatado[256];
va_list ap;
@@ -99,7 +99,7 @@
escrever(fonte,x,y,textoFormatado);
}
//Escreve na tela usando recursos de Localização (Tradução), baseado na
junção de dois segmentos de localização
-void WriteManager::escreverLocalizadoSubChave(const std::string fonte, int
x, int y, const std::string chave, const std::string subChave)
+void WriteManager::escreverLocalizadoSubChave(const std::string fonte, int
x, int y, const std::string chave, const std::string subChave)
{
char textoFormatado[256];
@@ -107,25 +107,27 @@
escrever(fonte,x,y,textoFormatado);
}
//Remove uma fonte (WriteSystemFontBitmap)
-void WriteManager::apagar(std::string nome)
-{
- if (objetomap[nome]){
+void WriteManager::apagar(std::string nome)
+{
+ // if (objetomap[nome]){
+ if (objetomap.find(nome)!=objetomap.end()){
delete (objetomap[nome]);
objetomap[nome]=NULL;
objetomap.erase(nome);
}
}
//Retorna em Pixel o tamanho total da linha
-int WriteManager::getLarguraLinha(const std::string fonte, const
std::string chave)
-{
- if (objetomap[fonte]){
+int WriteManager::getLarguraLinha(const std::string fonte, const
std::string chave)
+{
+ //if (objetomap[fonte]){
+ if (objetomap.find(fonte)!=objetomap.end()){
return
objetomap[fonte]->getLarguraLinha(idioma->getTexto(chave).c_str());
} else {
return 0;
}
}
//Construtor
-WriteManager::WriteManager()
+WriteManager::WriteManager()
{
// UtilLog::subSistema("Instanciando WriteSystemManager");
idioma = Idioma::getInstance();