Zurück   Flashforum > Flash > Stuff

Antwort
 
LinkBack Themen-Optionen Ansicht
Alt 19-08-2005, 10:33   #1 (permalink)
Nordlicht
 
Benutzerbild von astaroth
 
Registriert seit: Jun 2001
Ort: Hamburg
Beiträge: 569
Post [stuff] InfoPanel

Keine Ahnung, ob das jemand gebrauchen kann, hab es allerdings für eine Applikation gebraucht. Kann schnell angeglichen werden.

Einfach COPY & PASTE

ActionScript:
  1. MovieClip.prototype.makeSideMenu = function(xpos, ypos) {
  2.     this.createEmptyMovieClip("Leiste", 1);
  3.     this.Leiste.PanelPress = false;
  4.     this.Leiste.createEmptyMovieClip("Ghost", 10);
  5.     with (this.Leiste.Ghost) {
  6.         moveTo(0, 0);
  7.         lineStyle(0, 0x000000, 0);
  8.         beginFill(0x000000, 0);
  9.         lineTo(0, 100);
  10.         lineTo(10, 100);
  11.         lineTo(10, 0);
  12.         lineTo(0, 0);
  13.     }
  14.     this.Leiste._x = xpos;
  15.     this.Leiste._y = ypos;
  16.     this.Leiste.createEmptyMovieClip("Dragger1", 11);
  17.     with (this.Leiste.Dragger1) {
  18.         moveTo(11, 0);
  19.         lineStyle(0, 0x000000, 0);
  20.         beginFill(0x000000, 0);
  21.         lineTo(11, 100);
  22.         lineTo(20, 100);
  23.         lineTo(20, 0);
  24.         lineTo(11, 0);
  25.     }
  26.     this.Leiste.Dragger1.useHandCursor = false;
  27.     this.Leiste.Dragger1.onPress = function() {
  28.         this._parent.startDrag(false);
  29.     }
  30.     this.Leiste.Dragger1.onRelease = this.Leiste.Dragger1.onReleaseOutside = function (){
  31.         this._parent.stopDrag();
  32.     }
  33.     this.Leiste.Ghost.onPress = function() {
  34.         if (this._parent.PanelPress == false) {
  35.             this._parent.PanelPress = true;
  36.             this._parent.LeistePic2._rotation = 180;
  37.             this._parent.LeistePic2._x += 9;
  38.             this._parent.LeistePic2._y += 11;
  39.             with (this._parent.Content) {
  40.                 lineStyle(1, 0x808080, 100);
  41.                 beginFill(0xFFFFFF, 100);
  42.                 moveTo(0, 0);
  43.                 lineTo(0, 100);
  44.                 lineTo(-250, 100);
  45.                 lineTo(-250, 0);
  46.                 lineTo(0, 0);
  47.                 endFill();
  48.             }
  49.             this._parent.Content.createEmptyMovieClip("ContentGrafik", 8);
  50.             with(this._parent.Content.ContentGrafik){
  51.                 moveTo(-248,22);
  52.                 lineStyle(1,0x000000,100);
  53.                 lineTo(-2,22);
  54.                 createEmptyMovieClip("CloseBtn",1);
  55.                 createTextField("TF1",100,-200,1,100,20);
  56.                 TF1.text = "You are here :";
  57.                 TF1.selectable = false;
  58.                 TF1.multiline = false;
  59.                
  60.                 with(CloseBtn){
  61.                     moveTo(-245,5);
  62.                     lineStyle(1,0xF0F0F0,100);
  63.                     beginFill(0xFFFFEE,100);
  64.                     lineTo(-245,20);
  65.                     lineStyle(1,0x808080);
  66.                     lineTo(-230,20);
  67.                     lineTo(-230,5);
  68.                     lineStyle(1,0xF0F0F0,100);
  69.                     lineTo(-245,5);
  70.                     endFill();
  71.                     moveTo(-244,6);
  72.                     lineStyle(1,0x000000,100);
  73.                     lineTo(-231,19);
  74.                     moveTo(-231,6);
  75.                     lineTo(-244,19);
  76.                 }
  77.                 CloseBtn.onPress = function (){
  78.                     this._parent._parent._parent.removeMovieClip();
  79.                 }
  80.                 createEmptyMovieClip("Btn1",11);
  81.                 with (Btn1){
  82.                    
  83.                     createTextField("InfoTF",1,-245,25,200,60);
  84.                    
  85.                     InfoTF.selectable = false;
  86.                     infoTF.border = false;
  87.                     //InfoTF.type = "dynamic";
  88.                     InfoTF.multiline = true;
  89.                     InfoTF.wordWrap = true;
  90.                     InfoTF.text = _root.mytext;
  91.                     //InfoTF.embedFonts = true;
  92.                     //InfoTF.setTextFormat(_root.newFormTF);
  93.                 }
  94.             }
  95.             this._parent.Content._alpha = 80;
  96.         } else {
  97.             this._parent.PanelPress = false;
  98.             this._parent.LeistePic2._rotation = 0;
  99.             this._parent.LeistePic2._x -= 9;
  100.             this._parent.LeistePic2._y -= 11;
  101.             with (this._parent.Content) {
  102.                 clear();
  103.                 for (i in this._parent.Content) {
  104.                     this._parent.Content[i].removeMovieClip();
  105.                 }
  106.             }
  107.         }
  108.     };
  109.     with (this.Leiste) {
  110.         moveTo(0, 0);
  111.         ratios = [00, 255];
  112.         colors = [0xC0C0C0, 0xFFFFFF];
  113.         alphas = [100, 100];
  114.         matrix = {matrixType:"box", x:0, y:0, w:20, h:5, r:0};
  115.         beginGradientFill("linear", colors, alphas, ratios, matrix);
  116.         lineStyle(0, 0x000000, 30);
  117.         lineTo(0, 100);
  118.         lineTo(20, 100);
  119.         lineTo(20, 0);
  120.         lineTo(0, 0);
  121.         endFill();
  122.         moveTo(20, 0);
  123.         lineStyle(0, 0x000000, 10);
  124.         lineTo(20, 100);
  125.         createEmptyMovieClip("LeistePic1", 4);
  126.         LeistePic1._x = 8;
  127.         with (LeistePic1) {
  128.             moveTo(0, 5);
  129.             lineStyle(1, 0x808080, 100);
  130.             lineTo(0, 40);
  131.             moveTo(1, 5);
  132.             lineStyle(1, 0xFFFFFF, 100);
  133.             lineTo(1, 40);
  134.             moveTo(0, 60);
  135.             lineStyle(1, 0x808080, 100);
  136.             lineTo(0, 95);
  137.             moveTo(1, 60);
  138.             lineStyle(1, 0xFFFFFF, 100);
  139.             lineTo(1, 95);
  140.         }
  141.         createEmptyMovieClip("LeistePic2", 5);
  142.         LeistePic2._y = 44;
  143.         LeistePic2._x = 2;
  144.         with (LeistePic2) {
  145.             moveTo(8, 0);
  146.             beginFill(0xF0F0F0, 100);
  147.             lineStyle(1, 0x606060, 100);
  148.             lineTo(8, 10);
  149.             lineTo(0, 5);
  150.             lineTo(8, 1);
  151.             endFill();
  152.             moveTo(7, 1);
  153.             lineStyle(1, 0xFFFFFF, 100);
  154.             lineTo(7, 9);
  155.             lineTo(0, 4);
  156.             lineTo(7, 0);
  157.         }
  158.         createEmptyMovieClip("Title", 2);
  159.         Title._x = 10;
  160.         Title._y = 4;
  161.         with (Title) {
  162.             moveTo(5, 1);
  163.             lineStyle(0, 0x000000, 90);
  164.             lineTo(5, 9);
  165.             moveTo(3, 11);
  166.             lineTo(3, 18);
  167.             moveTo(3, 11);
  168.             lineTo(7, 18);
  169.             lineTo(7, 11);
  170.             moveTo(3, 21);
  171.             lineTo(3, 28);
  172.             moveTo(3, 25);
  173.             lineTo(6, 25);
  174.             moveTo(3, 21);
  175.             lineTo(7, 21);
  176.             moveTo(3, 31);
  177.             lineTo(3, 38);
  178.             lineTo(7, 38);
  179.             lineTo(7, 31);
  180.             lineTo(3, 31);
  181.             moveTo(3, 41);
  182.             lineTo(3, 49);
  183.             moveTo(3, 45);
  184.             lineTo(7, 45);
  185.             lineTo(7, 41);
  186.             lineTo(3, 41);
  187.             moveTo(3, 52);
  188.             lineTo(3, 59);
  189.             moveTo(3, 52);
  190.             lineTo(7, 52);
  191.             lineTo(7, 59);
  192.             moveTo(3, 55);
  193.             lineTo(7, 55);
  194.             moveTo(3, 62);
  195.             lineTo(3, 69);
  196.             moveTo(3, 62);
  197.             lineTo(7, 69);
  198.             lineTo(7, 62);
  199.             moveTo(3, 72);
  200.             lineTo(3, 79);
  201.             lineTo(7, 79);
  202.             moveTo(3, 75);
  203.             lineTo(6, 75);
  204.             moveTo(3, 72);
  205.             lineTo(7, 72);
  206.             moveTo(3, 82);
  207.             lineTo(3, 89);
  208.             lineTo(7, 89);
  209.         }
  210.         createEmptyMovieClip("Content", 1);
  211.     }
  212. };
  213. // Beispiele :
  214. mytext = "Dies ist nur wieder ein weiterer Versuch etwas zu basteln, was in die Applikation soll !";
  215. makeSideMenu(100, 50);
  216. createEmptyMovieClip("Win",100);
  217. Win.makeSideMenu(200,100);
  218. createEmptyMovieClip("Win2",101);
  219. Win2.createEmptyMovieClip("ja",102);
  220. Win2.ja.makeSideMenu(200,202);


...Patrick
__________________
"Wir müssen die Rechte der Andersdenkenden selbst dann beachten, wenn sie Idioten oder schädlich sind. Wir müssen aufpassen."
Wachsamkeit ist der Preis der Freiheit - Keine Zensur!

– Wau Holland –

http://www.wauland.de
astaroth ist offline   Mit Zitat antworten
Alt 19-08-2005, 10:45   #2 (permalink)
tracer
 
Benutzerbild von andretti
 
Registriert seit: Jun 2004
Beiträge: 4.415
Thumbs up

aloha!

tolles teil!

...ist das beabsichtigt, dass bei klick auf das kreuz des infofensters das ganze menü verschwindet?

edit: "INFOPANEL" so zu schreiben ist auch nicht schlecht, aber Menge Arbeit, ich würde nach dem 2.etn Buchstaben durcheinanderkommen
__________________
Viola per Sempre
Alle Angaben ohne Gewehr!
trace your open mind in variables !
andretti
ActionScript Dictionary

Geändert von andretti (19-08-2005 um 10:53 Uhr)
andretti ist offline   Mit Zitat antworten
Alt 19-08-2005, 10:49   #3 (permalink)
Nordlicht
 
Benutzerbild von astaroth
 
Registriert seit: Jun 2001
Ort: Hamburg
Beiträge: 569
ja, ist beabsichtigt, da Du ja im vorderen Teil vom InfoPanel, das Fenster nur wieder zumachst und der hintere Teil damit dragst Du die Leiste.

Probiere es einfach aus.
__________________
"Wir müssen die Rechte der Andersdenkenden selbst dann beachten, wenn sie Idioten oder schädlich sind. Wir müssen aufpassen."
Wachsamkeit ist der Preis der Freiheit - Keine Zensur!

– Wau Holland –

http://www.wauland.de
astaroth ist offline   Mit Zitat antworten
Alt 19-08-2005, 11:57   #4 (permalink)
tracer
 
Benutzerbild von andretti
 
Registriert seit: Jun 2004
Beiträge: 4.415
aaaaaaah ja, aber ein unabsichtlicher klick, und die infoleiste is weg

ActionScript:
  1. CloseBtn.onPress = function() {
  2.                     this._parent._parent._parent.removeMovieClip();
habe versucht, nur "this._parent" zu removen, aber der rahmen bleibt dennoch;

geht das irgendwie?
oder wie hast du das angedacht?
soll das infopanel immer bei einem klick erscheinen?....so wie ein tooltip?
__________________
Viola per Sempre
Alle Angaben ohne Gewehr!
trace your open mind in variables !
andretti
ActionScript Dictionary
andretti ist offline   Mit Zitat antworten
Alt 19-08-2005, 12:07   #5 (permalink)
Nordlicht
 
Benutzerbild von astaroth
 
Registriert seit: Jun 2001
Ort: Hamburg
Beiträge: 569
Klaro geht das :

ActionScript:
  1. CloseBtn.onPress = function() {
  2.         this._parent._parent.clear();
  3.         this._parent.removeMovieClip();
  4. }

Edit:
Ja, sollte immer erscheinen, so war zumindest die Anforderung.
__________________
"Wir müssen die Rechte der Andersdenkenden selbst dann beachten, wenn sie Idioten oder schädlich sind. Wir müssen aufpassen."
Wachsamkeit ist der Preis der Freiheit - Keine Zensur!

– Wau Holland –

http://www.wauland.de
astaroth ist offline   Mit Zitat antworten
Antwort

Lesezeichen

Themen-Optionen
Ansicht

Forumregeln
Es ist Ihnen nicht erlaubt, neue Themen zu verfassen.
Es ist Ihnen nicht erlaubt, auf Beiträge zu antworten.
Es ist Ihnen nicht erlaubt, Anhänge hochzuladen.
Es ist Ihnen nicht erlaubt, Ihre Beiträge zu bearbeiten.

BB-Code ist an.
Smileys sind an.
[IMG] Code ist an.
HTML-Code ist aus.
Trackbacks sind an
Pingbacks sind an
Refbacks sind an



Alle Zeitangaben in WEZ +1. Es ist jetzt 18:31 Uhr.

Domains, Webhosting & Vserver von Host Europe
Unterstützt das Flashforum!
Adobe User Group


Copyright ©1999 – 2012 Marc Thiele