View Single Post
  #10  
Old 11-22-2010, 06:13 AM
fowlplay4 fowlplay4 is offline
team canada
fowlplay4's Avatar
Join Date: Jul 2004
Location: Canada
Posts: 5,200
fowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond repute
Quote:
Originally Posted by Supaman771 View Post
Windows Photo Gallery?
Change folder view to full tiles?
Etc?
Write your own!

PHP Code:
//#CLIENTSIDE

function onCreated() {
  
createGUI();
}

function 
createGUI() {
  if (
isObject("Heads")) Heads.destroy();
  
// Load Heads
  
temp.files.loadfolder("levels/heads/*", false);
  
temp.spaces = int(400 / 32) - 1;
  
// Create GUI
  
new GuiWindowCtrl("Heads") {
    
width = 400 - 24;
    
height = 300 + 12;
    
isexternal = true;
    
text = "Head Viewer";
    new 
GuiScrollCtrl("Heads_Scroll") {
      
x = y = 2;
      
width = Heads.width - 4;
      
height = Heads.height - 4;
      
this.clearcontrols();
      
// Add Heads
      
for (temp.file: temp.files) {
        new 
GuiShowImgCtrl("Head_" @ extractfilebase(temp.file)) {
          
x = 32 * (temp.i % temp.spaces);
          
y = 32 * int(temp.i / temp.spaces);
          
image = temp.file;
          
partw = parth = 32;
          
partx = 0;
          
party = 32 * 2;
          
thiso.catchevent(this.name, "onMouseDown", "onHeadSelected");
        }
        
temp.i++;
      }
    }
  }
}

function 
onHeadSelected(obj) {
  echo(
obj.image);
} 
I could really make this thing shine had I put more than 15 minutes into it.
Attached Thumbnails
Click image for larger version

Name:	cap.JPG
Views:	879
Size:	67.4 KB
ID:	51967  
__________________
Quote:
Reply With Quote