displayobject

Adding to Stage in ActionScript 3 from a .as file

ぃ、小莉子 提交于 2019-12-13 07:36:11
问题 Note: Yes, I know that similar questions have been asked before. However, after following the answers in such questions I'm still stuck and can't find a solution to my problem. I'm having a problem which requires adding DisplayObjects to the Flash stage. Since I have to Display elements of several different classes, I decided to create a class to work as an intermediary between the .as files and the addChild function called "Displayer" as shown below: package { import flash.display

hitTestObject with dynamically add movies

核能气质少年 提交于 2019-12-13 07:24:32
问题 I have code that adds a movie clip to the stage. The problem is, after it is added I want to add a hitTestObject on that object instance however I keep getting this error: TypeError: Error #1034: Type Coercion failed: cannot convert "ast_0" to flash.display.DisplayObject. at spaceranger_fla::MainTimeline/addAstroid() at flash.utils::Timer/_timerDispatch() at flash.utils::Timer/tick() Here is my code: // Add astoid var astTimer:Timer = new Timer(5000); astTimer.addEventListener(TimerEvent

php search issued file

丶灬走出姿态 提交于 2019-12-12 06:46:12
问题 My script search in a category for a file and then must display the file. Example: the X user is searching in category PCgames for Y game. After the X user push the "Search" button script must display all the files found in category. But I have some issues in the script search.php file: <html> <body> <center> <font color="black" size="4"> <?php //define each directory here, the index starts with 0 == all and so on. $categorydir = array('/Category/All/', '/Category/PCGames/', '/Category

Lua: how do I add display objects required from external functions to display groups?

匆匆过客 提交于 2019-12-11 20:48:14
问题 In a storyboard scene, I require a bunch of display objects from external functions. When I attempt to add these to the scene's display group, I get the error "table expected." function scene:createScene(event) local group=self.view local shieldDisplay = shieldDisplay.new() group:insert(shieldDisplay) end The external function looks like this: function shieldDisplay.new() shieldDisp = display.newText("Shield: "..tostring(Cshield), 1165, 20, native.systemFont, 30) shieldDisp:setTextColor(9,205

Display:Flex not supported in Safari?

别等时光非礼了梦想. 提交于 2019-12-11 12:42:51
问题 The drop down menus on this site fire off on hover, and then when active, they appear horizontally by using 'display: flex;' in CSS. Can't figure out how to get this to work with Safari though. It works in Chrome, but not Safari. www.soakandswim.com/wp/pools <--for reference. Any insight? Thanks! 回答1: Some browsers do not fully support all the CSS3 elements. Try this: display: -webkit-box; display: -moz-box; display: -ms-flexbox; display: -webkit-flex; display: flex; 来源: https://stackoverflow

Removing Parent in AS3: Does this free the memory used by all the children?

我们两清 提交于 2019-12-10 23:47:44
问题 I'm making a rather large flash project and so I'm concerned about memory usage. At the end of each section of the application I remove the overarching parent element that holds the content. Although this remove the parent, does this also free up the memory for each of the children contained within this, or should I run an iteration to remove those prior to removing the parent? I'll give a little more explanation in-case I'm not expressing what I want: addChild(movie1); movie1.addChild(movie2

Draw text on shape in ActionScript 3

橙三吉。 提交于 2019-12-10 03:28:54
问题 Is there any way to draw text in a DisplayObject or Shape using only ActionScript? The only way I can find on the web is by creating a TextField, but I can't add a TF to a DisplayObject or Shape. Edit: Solved thanks to viatropos. For anyone that's interested: DisplayObject implements IBitmapDrawable which can be passed as an argument to the draw function of a BitmapData object, which then can be drawn using graphics.beginBitmapFill . var textfield:TextField = new TextField; textfield.text =

Javascript search and display divs with matching keywords

让人想犯罪 __ 提交于 2019-12-04 13:18:45
问题 What I'm looking for: I'm working on creating an easy way for a user to search a list of people, and for results to instantly display below the search field. The results MUST display "close" results, rather than exact. For example: User searches for "Mr. Smith" and The following existing result is displayed: "John Smith" (since there is no "Mr. Smith" entry, it displayed one with the keyword "smith") What I have: I have a working code that lets the user enter some characters and all divs that

as3 mouseEnabled still a problem for me

冷暖自知 提交于 2019-11-30 12:56:47
A couple years in now, there's still something about mouseEnabled I'm not getting. I have a Sprite (for example here "Sky", that contains many objects, one of them is a Cloud, which I do not want to receive Mouse Events. I overlay this Sky on some other display objects. I want the cloud to be visible, but not to block mouse events. If you see a tree through the clouds you should be able to click on the tree. In the Sky class: mouseEnabled = false; cloud.mouseEnabled = false; cloud.mouseChildren = false; Even with this configuration, when the cloud is over the tree I can't click on the tree

displaying a pdf from a local drive in shiny

徘徊边缘 提交于 2019-11-27 08:04:55
I'm still new to r and shiny, and i'm stumped with what should otherwise be simple logic. I am trying to display pdf files in imageOutput widgets but with no luck. Could someone steer me in the right direction? sample ui.R shinyUI(pageWithSidebar( mainPanel( selectInput("sel_ed", label = "View outputs for Ecodistrict:", choices = c(244,245,247,249), selected = NULL, multiple = FALSE), imageOutput("imp_pdf",width="500px",height="500px") )) sample server.R shinyServer(function(input, output, session) { importance <- function(inputSpecies){ img_dir <- pdf(paste(inputSpecies,"\\models\\MATL\\MATRF