Monday, November 28, 2011.

Working on flip cards and fraction strips and fraction squares.
I added a few new helpers and now all of the files for the fraction strips are 32k or under.
You can also add placeHorizontal in the initObj for the fraction strips and the fraction squares so they show up horizontal in the tool talk animation.
So now the builder pods are gone and the flip cards are looking much better.
I've got the tools on the cards defaulting to a good location and size depending on the size of the cards and the text for the symbolic representation is also centered no matter how big the card is.
The location of where the tools show up is not really intuitive since you're actually setting the location of the builder in most cases, but that is invisible, so I'm going to try to play around with it so if they set the location of the tool it will show up where you would expect.

Monday, November 21, 2011.

Working on the graphing calculator.
The graphing calculator got split up into more helper functions, which made the mouse modes stop working, but it turns out one function wasn't returning anything anymore, so that is fixed and the mouse modes are working again.
I got rid of all the extra calls to makeGraphs() while loading the xml, so it is loading much faster now.
When loading the xml some things that weren't loading or changing properly before that are now working are: the status bar message, ticks every, the values of the parameters (the boxes don't overlap anymore now either), the parameter names on the numpad change and light up correctly now, and I've changed location to have display and enabled attributes as well as the coordinates, colour, and size.

Thursday, November 17, 2011.

Working on the graphing calculator.
In the function for getting the xml code, I've got all the parameters set up in ubCalculator.
Now I am setting up the getProp function in the brain and making sure all the parameters that I need to pull out get changed at the appropriate times, and I've got most of them working now. The function now gives back the correct values for the skin colour, the angle mode, the skin colour, and for each equation, whether it is enabled, it's colour index and thickness index, and what the equation is.
Also you can now close the parameter pod without everything closing. :)

Wednesday, November 16, 2011.

Working on the graphing calculator.
I noticed that you can scale by xpi (x<=1) and the graph works fine, but for x>1, it doesn't. For labeling every 2pi, the numberline stops at 2pi, but labels are at -pi and pi. I've looked at all the traces for the ubNumberline2 init and they're all what I would expect them to be so I can't figure out why that isn't working properly.
I've changed the math parser so that 2pi (where pi is the unicode character given by the number pad) is acceptable and no multiplication sign is needed anymore.
The rad/deg label on the calculator is back and working.
Crystal noticed that if you switch the graphing calculator to one of the other calculators then all the mouse events for the graphing calculator are still being picked up. So in ubCalculator I've deleted the graphing calculator when you leave it. So when you switch back to the graphing calculator it is set back to the defaults.
I think the list of things to fix is getting a lot shorter!

Tuesday, November 15, 2011.

Working on the graphing calculator.
The "ticks every" are now updating onKillFocus. It reduces the fraction, and if they are labeling by some multiple of pi then pi stays in the answer (ie labeling by 2pi and 3 divisions gives ticks every "2π/3").
If you are labeling by something like ln(3), that doesn't give you a fraction, then the ticks every will be a decimal and I round it to 4 decimal places.
The square button is working now. Clicking it will change the value in the ymax box, but doesn't change the graph until you hit apply changes.
The reset window button is working and resets all values in the pod, but again doesn't change the graph until apply changes.
I've also changed the setup of all the menus in the graphing calculator and the numpad so that other pods will be on a higher layer than the button, but a lower layer than the menu.
The numpad and snapshot buttons now don't scale with the pod because they are not on the inside, but onPodResize moves them to the right place.

Monday, November 14, 2011.

Working on th graphing calculator.
The windows pod is completely overhauled.
I have it all functioning how it was before, but everything updates onKillFocus or onChanged, rather than everything changing when after pressing the Apply Changes button.
Everything is highlighting at the right time and the graphs are being made properly, and "label every" is being updated when you change the min/max.
Also when you change the label every box, the auto scale automatically turns off.
I think all that is left to change is updating the display of where the ticks occur when you change the number or divisions, and getting the square button working, then testing.

Wednesday, November 9, 2011.

Working on the graphing calculator.
I've switched around the domain pod so you can scale the x and y axis (and soon there will be the ability to reduce fractions or not).
It looks like the y-axis scaling is all working properly, but probably needs to be tested more.
I also noticed that the auto-scaling wasn't working, but I moved around the if statements and that is working now too.
In the process though I noticed that some of the mouse modes aren't working now (especially pan) so that is what I'm investigating next.

Thursday, November 3, 2011.

Working on ubFlipCards.
I've added in the possibility of having a card be a symbolic representation rather than a tool.
Instead of passing in the tool's init object you pass in what strings you want the card to show at each step. (It doesn't need to be the same number of steps as the tools and it will still work, as long as there is at least one step).
This seems to be working again with the symbolic. It plays through all the steps and you can replay all the steps and it works the same as the tools.
I realized that I had had it working for a specific number of steps, but that different fractions may require a different number of steps in the animation.
Now the replay process is more generalized and should work for all sorts of different fractions.
There are lots of different things I am in the process of testing for, and it is taking a while since the animations run so slowly, but I think I may be close to getting Crystal to look at it and see what else she wants it to do.

Wednesday, November 2, 2011.

Working on the graphing calculator and flip cards.
The parameters are now a little smarter about what they can be called.
If the name of a parameter is changed it checks to make sure that there isn't already a parameter with that name and also makes sure that the parameter isn't named "x".
If either of those happen the parameter name gets changed back to what it was before and a message appears in the status bar describing what went wrong.
I changed the border colour of the parameter and domain pod to be the background colour of the graphing calculator pod.
I tried the same border colour at first, but with the white background it didn't look very good.
Working on the flip cards, I have it working through all the animations now.
Clicking a card will flip it and play the animation, once all four have been played the replay button appears and clicking that will play through one step of the animation at a time (all of the tools at once).
It runs very slowly and choppy, but maybe it will be better on a mac?
Working on making sure things aren't clickable during animations and working in the option for a numerical representation.

Tuesday, November 1, 2011.

Working on the graphing calculator.
The pan mouse mode now pans slower so it doesn't run away on you (I explained it more in the google doc).
Now the numpad displays "arcsin" instead of "asin" and the buttons all say "arc" now too.
The MathParser understands it both ways, but just for the graphing calculator asin(x) will give an error.
The graph now updates more frequently. So if the parameter "b" is not activated and you type in the equation "x^+b" and THEN activate the parameter b, the graph will change and the equation will be valid.
The sliders for the parameters all default to 1 now instead of 0 so it's less confusing when the graph doesn't show up at first because all the parameters are 0.
Now when an equation is invalid, the status bar has specific feedback for what may be wrong with the equation, rather than just the generic "incomplete equation".
Most of the feedback from the parser was pretty good already, the only one that was ambiguous and potentially confusing was "unknown character" if there was any character that isn't a parameter.
So if it's one character long it says to make sure the parameter is active, and if not it says to consider using a multiplication sign between parameters.
Although asin, acos, and atan all have their own cases of "Did you mean a*sin?"
And all the invalid equation feedback shows up in orange.

Friday, October 28, 2011.

Working on ubFlipCards.
Greg figured out why the toolTalk.doFeedback wasn't working. :)
I didn't have the hand icon in my tester's library, so now that is working!
I'm trying to get it to work with the least amount of parameters in the init object as possible, but then also let them customize as much as they want.
So I've picked four tools that show up automatically with defaults, and I will make defaults for all the tools with toolTalks, (like showing up without the gears etc etc).
I have it working to the point where you can click on a card, it flips and plays the toolTalk (you can' click any other cards when this is playing), and once all four get played a replay button appears.
Clicking the replay button plays the first step of the doFeedback starting from the beginning for all of the tools at once. It works, but it is pretty slow. So far it hasn't crashed flash for me though!

Thursday, October 27, 2011.

Working on ubFlipCards.
You can now click on a card, it flips over, and a tool appears.
The tool is actually working now too (took me a while to realize I needed to delete the cell's onPress function for the tool to work).
Now I'm trying to get the toolTalk to work for all the tools. Right now "Complete" just highlights the builder.
So I'm trying to get it working for just a stand alone tool first, see how that works, then if I can get that up and going I'll try again with the tool in the cell of a table.

Wednesday, October 26, 2011.

Working on ubFlipCards.
I have the initial set of cards showing up with lots of different ways to customize it. (size, colour, etc).
When you click on a card it flips over (I think it looks pretty cool right now, but I might be able to make it look better).
After lots of phone calls Crystal and I figured out exactly how adding the tool to the cards and the toolTalk for them was going to work.
So now I'm working on getting the tools added and getting them to play the animations at the right time etc.

Monday, October 24, 2011.

Finished adding the copyright pod and publish settings and testing to all of Cluster 2 and 5 while at flashfest.
I changed how the mouse modes work in the graphing calculator. Instead of the mouse mode locking when a pod is open, the calculator now checks to see if where you clicked is on the graph as well as a pod. So if a pod is overlapping the graph and you click on the pod the mouse mode won't activate, but clicking on the part of the graph that is not overlapping the pod will still work normally.
ubCalculator now broadcasts when the graphing calculator is reset so you can catch that and change where the pods are etc.
I've started ubFlipCards now and I have the skeleton of it set up now.

Tuesday, October 18, 2011.

Ross and I finally figured out what the problem with the four max/min text fields were (their properties were getting reset when .setText was called so afterwards the tabIndex and fromNumPad was undefined).
Then I tested all the activities in Clip 2, Cluster 3.
All the things I found I put in this google doc :

Monday, October 17, 2011.

Working on the stand alone calculator.
The domain pod is smaller now, looks a little better.
I've added in a camera icon button beside the number pad button so you can take screen shots of the stand alone calculator since the camera icon on the wrapper won't be there.
I've played around with it and it seems to be working fine, both capturing the whole screen or just a section.
The initial names of the parameters are now a, b, c, d, and m instead of a, b, c, d, and f, so they can more easily graph y = m*x+b.
Clear all parameters now inactivates all the parameters rather than setting them all the 0.
The treatAsNumericExpression flag wasn't working properly for the one text field that did pick up the flag, but now it is. I am still trying to figure out why it isn't working at all for the max/min text fields though.

Friday, October 14, 2011.

Since I updated last, the stand alone fla for the calculator is working.
I fixed a couple things in the mathParser (it can now parse log(x) as log with base 10).
The parameters are communicating and updating between the graphing calculator and the number pad.
The tab finally seems to be working, but there is definitely wonky with the min/max text fields.
Now that I am getting a treatAsNumericExpression flag going, it is working perfectly fine for the "label every" text field, (ie the equations pod shows up but you can't use any of the parameters) but it doesn't work for the other four.
In the function in ubNumPad myTextField.fromNumPad.treatAsNumericExpression gets set to true, and then sometime between then and when it is used in the numPadBrain to determine whether or not to open the equations pod, it changes to undefined. But only for 4 out of the 5 text fields that I do this for.
And also keeping tabs on what I'm working on here:

Friday, October 7, 2011.

Working on the calculator fla.
I made an fla for the ubCalculator for when the calculator is opened on its own in a web browser, after much mucking around with html.
It shows up in the tp left of the screen, unable to drag and without the close/minimize buttons.
However, when you switch to the graphing calculator that all comes back. All the calculators get made the same way and even when I change the defaults in graphCalcInterface it still appears draggable/closable.
I am still working on why that's happening, and at the same time started working on adding in a button for the graphing calculator to open the numPad since you will need that to use the graphing calculator on the smart board if you don't have a keyboard.

Thursday, October 6, 2011.

Working on the number pad.
Other than any little things we may find, I think the equations pod for inserting equations into the graphing calculator is basically finished.
I've got the comma working, so when you insert max or min it write max(, and moves the cursor to before the comma, and then there is a comma option as well in case it gets deleted.
There was some trouble getting it to work in the wrapper, but the tester I was using was just set up differently and now it all works.
The parameters buttons now get disabled when the corresponding parameter in the graphing calculator is not checked off.
The names of the buttons update with the names in the graphing calculator, and I got the tooltips working for when the name is too long.
You can also insert the absolute value function now.
a*sin(x) wasn't graphing if you activated the parameter "a" AFTER a*sin(x) was already typed. But now the graphing calculator is updating at the right times and will change the graph when a parameter is activated.
The sliders on the graphing calculator were changing all the parameter names to lower case, so I went into the slider and changed that so you can now have upper case letters in the parameter names as well.

Wednesday, October 5, 2011.

Working on the number pad.
I got the function menu label looking like all the other buttons after I finally figured out you have to set some of the button properties you want in the menu init, not the button init.
But I could not for the life of me get the menu working while it was an element in a ubTable.
So now it is made outside of the table and is working fine.
I got all the options in the function menu working (max, min, floor, and ceil) they are showing up in the text field and the graph updates accordingly.
I added in an open bracket for these too, like the trig functions.
Then I realized you can't use max or min without a comma, so I put that in the function menu too for now, unless there is somewhere better to put it, or if max and min should show up with a comma already in place and then they can arrow back a character to insert the first number.
I played around with the numPad and it seems to all be working well now so I've committed all my changes now if anyone wants to take a look. (I think the equation text fields on the graphing calculator are the only ones that will open the equations pod right now).

Tuesday, October 4, 2011.

Working on the number pad.
The buttons all broadcast to the graphing calculator when a change is made, so the graph will update automatically.
The number pad also picks up the names of the parameters from the graphing calculator and the labels on five buttons change with the parameters. If the parameter name is longer than 4 characters then the button just says Par1, Par2, etc. Then there will be a tool tip that says the actual parameter name (why do I always have such a hard time with tool tips??)
I am in the process of making the Func button into the label for a ubMenu which will have less popular functions like max, min, floor, and ceil, that didn't make in onto the pod.

Monday, October 3, 2011.

Working on the number pad.
The equations pod is turning visible/invisible at the right times (visible only when focus is on an equation text field).
The equation buttons are showing up in the text field correctly now and for sin, cos, tan, ln, log, and sqrt, they all show up with an open bracket ie "sin(" so they know they have to put the parameter in brackets. And after clicking a button that adds more than one character to the text field, the cursor shows up at the end, not just after the first character.
The "2nd" button is working now. sin -> asin, ln -> e^, ^2 ->sqrt, etc.
Now I need to make these new buttons broadcast their changes so the graph updates, get the parameter names to change, and get the function button doing whatever it is going to be doing.

Friday, September 30, 2011.

Working on numPadInterface.
I've made a pod for the numPad that will show up when you set focus on a text field that allows equations.
This equations pod has all the extra characters you'll need for typing equations like the trig functions, x, brackets, pi, +, -, *, /, ^, parameters etc.
It looks pretty similar to the scientific calculator. It doesn't do anything right now, so I need to get the buttons working, get the 2nd button working, and get the parameters buttons to pick up the names of the parameters from the graphing calculator.

Thursday, September 29, 2011.

Working on graphCalcBrain, ubCalculator, ubGraph, ubNumPad.
Mostly testing and fixing. It may be easier to read about it in the doc. (There are two tabs. One for the numPad and one for the calculator)

Wednesday, September 28, 2011.

Working on graphCalcBrain and numPad.
Since you can't change the graph when any pods are open, when pods are open the mouse mode says "locked", and when ALL the pods are closed, it goes back to whichever mouse mode it was before.
I noticed that you could click almost anywhere above the graph and it would change from rad to deg or vice versa. Now it is restricted to just the word.
The tab indices stopped working for a while, but they are working again.
Now I am testing the numPad for wonkiness and have a few in the NumPad and Graphing Calculator work doc.
Next I'm making an extra pod for the numPad with all the extra buttons you would need to enter equations into the graphing calculator.

Tuesday, September 27, 2011.

Working on graphCalcBrain and MathParser.
I changed how the reset button works a bit. Now instead of resetting to the sample equations the calculator starts out with, it clears the equations and the graph.
The tool tips are all working now, for the mouse mode and the information menu.
I took away the star in "2*x+1" sample equation since we don't want to imply they need the star for multiplication.
I fixed some stuff in the math parser. It was taking sin(x) but only if sin (or cos or ln, etc) was the very first thing in the string. 2sin(x) or 3+sqrt(x) wasn't working. But now it is.
I changed the size of the pi symbols so they are as big as the numbers.
I took out the multiline on any input text boxes. Especially in the domain pod where it doesn't change until you hit the Apply Changes button, so it may be habit to press enter to try to make the changes.
I cleaned up the code a bit more as I went.
I added an extra call to the function that makes the graphs onMouseUp since when panning too fast sometimes one of the axes didn't catch up all the way. I think that is working better now.
All the graphs now default to different colours and reset to those colours as well.
And I can't take credit for this, it was all Ross, but the tab indices are all working correctly now.
Now I am just getting the mouse mode to display that it's locked/unlocked at the right times (since if a pod is open they can't use any mouse modes on the screen).

Monday, September 26, 2011.

Working on graphCalcBrain and ubGraph.
I think scaling by pi is now working. You can flip between scaling by a multiple of pi to a whole number to auto scaling, and play around with all the mouse modes and the pi symbols are all staying in the right place. I wanted them to be able to see the important factors of pi, but it was really crowded and not really working, so now if they scale by pi/2, pi/3, pi/4, or pi/6 then the number line is labeled every pi, but there are ticks at every pi/x so it's still easy to see what the function is doing at that exact point.
However the labeling and ticks wasn't working right when I would set the scaling and then graph a trig function, but now the labels and ticks are all working and staying how they're set after graphing or changing mouse modes.
Also, when resetting the board, the only thing I've found so far that wasn't resetting properly was the locate dot. It would change colour and size, but would not change it's location. But I fixed that and now the board all resets properly.
I am trying to fix the tab index for the ubFramedText boxes that are on the calculator and in the domain pod. I have it working properly for all the equations and one of the text boxes in the domain pod, but for some reason it skips over the other four text boxes in the domain pod. And I'm also still working on figuring out why the tool tips aren't showing up.

Friday, September 23, 2011.

Working on graphCalcBrain and ubGraph.
I tried adding in a tool tip for the mouse mode display saying that it can be changed in the menu, but I can't get the tool tip to show up. Then I realized none of my tool tips were showing up. I'm not sure what that's about but after playing around with it for a while I gave up and will look at it again another day.
After fixing the ticks problem yesterday I realized it was labeling every tick and not just major ticks when you zoom in, which looked really squished. Now it labels correctly.
I dug around in ubGraph some more and I fixed the problem of the axes floating off the screen while panning. Now when they get to the edge of the graph they disappear, rather than only disappearing when the get to the edge of the calculator.
When graphing in radians and manually scaling to some multiple of pi, the pi symbols show up and in the right place. You can also pan and zoom and they still stay in the right spots.
I thought they should probably be able to scale by a factor of pi too. Probably the special angles like pi/2, pi/3, pi/4, pi/6. So I got that working but it was decimal numbers instead of fractions, which isn't really helpful. I'm trying to get it working with fractions right now, but every time I fix one thing it breaks 3 more things! So I am digging around ubNumberLine2 right now, seeing how it works, and hopefully I'll have the scaling all worked out soon.

Thursday, September 22, 2011.

Working on graphCalcBrain and ubGraph.
Ross and I changed stuff around in how ubGraph works and now there aren't a million ticks when you zoom out too far.
I've made some of the buttons on the calculator bigger so they are more legible.
I un-bolded the displays for the mouse mode and for rad/deg and changed the colour so it looks more like the displays on the scientific calculator.
I changed the text in the status bar to white instead of grey on grey so it's easier to read.
You can now click on the rad/deg display and it changes the display and the graph. I don't know if that is too easy to accidentally click on and change, so if it is I can change it so that when you click on it, rather than changing automatically, it opens the domain pod where you have the option of changing it.
The mouse mode display (right beside the mouse mode menu) now opens that menu when you click on it since it may not be intuitive where to click. But I noticed that when the menu opens from clicking on the display (which calls ubMenu.openMenu()) then the menu opens, but it's inactive and clicking on the different options doesn't do anything. I've been messing around with that but maybe that is something with ubMenu, or I need to reactive the listener somehow after calling openMenu? If that doesn't work out maybe I will just add a tool tip over the display saying to click on the menu.

Wednesday, September 21, 2011.

Working on graphCalcBrain and ubSlider.
I finished splitting graphCalcBrain into two helpers. All the setup stuff is in one, and all event handlers are in the other. Now graphCalcBrain is about half as big as it was.
I worked around in ubSlider a bit and now you can change the name of the parameters, and you can change the parameters' values by the box or the slider and they both work and the graphs change accordingly.
I changed a line in ubGraph so that those zeros don't show up in the middle of the graph anymore. I hope that doesn't mess anything up for anything else.
Ross pointed out that if you zoom out far enough there are too many ticks, so when I looked into that I realized that ubGraph.tickAxes() wasn't drawing the minor ticks at the value passed to it. I looked at ubGraph and saw that the tickAxes function is all in an "if" statement with the parameter being "false", so nothing in that function ever gets called. So I tried looking around ubGraph for where the ticks DO get redrawn, but I've never looked at ubGraph before and I can't seem to find where that is happening. Because even when I comment out the call to tickAxes, labelAxes, drawGrid, and drawAxes.. it still draws those millions of ticks! Maybe someone more familiar with ubGraph knows what's going on.
I started on my list of previously abandoned things (fixing the zeros was one of them). Now I am trying to fix the axes floating off the screen when you pan (also I think something that is happening in ubGraph), and also figuring out how to get the pi symbols to show up in the right places when scaling by some multiple of pi.

Tuesday, September 20, 2011.

Working on graphCalcBrain.
I figured out the menu/button issue and now the info menu title is the blue "i" button like the other calculators.
I added in option buttons to the settings pod where you can change the mouse mode. Now they can be changed in the menu or in settings. I have both of those places synced with each other so if you change the mouse mode in the menu and then open the settings pod the correct option is highlighted and the zoom option displays the correct factor.
Now I am working on cleaning up the code. There is lots of code that wasn't being used anymore I got rid of, and also started making helpers today. Now I am not getting the error that the code is too big and it's about 600 lines shorter.
Next I am going to look into ubSlider to fix some issues with the parameters, and go back to things that I wanted to fix before but got stuck and gave up on.

Monday, September 19, 2011.

Working on graphCalcBrain.
I noticed that sometimes if you clicked on the menu the mouse mode would still activate. It isn't doing that anymore now and you can switch mouse modes without zooming in an extra time.
Now rather than there being a label that says "mouse mode:", that is now where the mouse mode menu is, so that there is more room above the graph and it doesn't say "mouse mode" twice.
I've made the info menu, although right now the title just says "i". I'm not sure how to make the title a button like all the other calculators. I may just be using titleButtonArray wrong?
The menu has "Keywords", which shows, in a pod, all the words that can be parsed in the equations (sin, max, ln, etc), "Settings",which has a pod with a button to clear all the parameters and another to reset the entire board (I'm not sure what else should go in there), and also "About" which is just the same pod as the basic calculator saying whose work the calculator was based on.
All those pods can also be opened and clicked on without the graph zooming in behind it.

Friday, September 16, 2011.

Working on graphCalcBrain.
Now when you switch between degrees and radians there is a small display on the calculator that tells you which mode you're in, so it's displayed if they want to save a picture of their graph.
All the buttons in the bottom right corner are resized and moves around a bit so that the text on the buttons is legible.
The place on the calculator that displays the point in locate mouse mode is changed around so that it has the same setup as the equations underneath it, so they all look consistent. The locate point also has a sizePicker now, so you can change the size of the point if you're zooming in and out. The locate also resets correctly now except for the sizePicker. The colourPicker has a setProp(), but sizePicker doesn't seem to have one so after being set it can only be changed by the user.
Now when you are in a mouse mode and click on a different mouse mode out of the menu (which overlaps the grid) clicking on the menu will not active the mouse mode you were just in. (ie if you're in zoom mode and click on the mouse mode menu, the graph won't zoom in).
The status bar on the calculator changes depending on the active parameters, and when no parameters are active it says "No parameters active".
And the graph now also graphs the arc trig functions in radians and degrees. It doesn't show the limits very well, and only graphs one cycle, but I think that is more of an issue with ubGraph.
Next on my list of things to do is getting the info menu and all it's pods working.

Thursday, September 15, 2011.

Working on graphCalcBrain.
Trig functions now graph properly in degrees and radians.
The parameters that show at the bottom of the calculator only show up when the parameter is active. I did notice though that ubSlider.getValue() will only get the proper value if the value has been changed by dragging the slider. If it's changed in the text box, the change doesn't register.
I am also working on having the user able to scale the x-axis by multiples of pi. It is working properly, the only thing that isn't there are the little "pi" symbols beside the number. But if you are scaling by 2pi, the 2, 4, 6.. are all showing up in the correct spots.
I am changing the "mouse mode" menu title to be the original mouse mode button, but instead of opening the pod it will open the menu. Although openMenu() doesn't seem to be working so it doesn't do anything right now.
Ross also gave me a list of things that need tweaking that I am chipping away at.

Wednesday, September 14, 2011.

Working on graphCalcBrain and MathParser.
The user can now select auto scale, or manual scale and the graph scales accordingly.
The graphs also weren't redrawing at the right times, so now they redraw/disappear when they are supposed to.
I started working on deg/rad mode and noticed that in degree mode you could ONLY plot trig functions, anything else would disappear, so that isn't happening anymore. You can graph a trig and a polynomial on the same graph.
Then Ross and I got into MathParser to figure out why a bunch of functions wouldn't graph. Now decimals, negatives, and trig functions, and some functions with brackets in weird places can all be understood by the parser.
Next I am getting the calculator to graph all the trig functions correctly depending on whether it is degrees or radians.

Tuesday, September 13, 2011.

Working on graphCalcBrain.
I've got the new domain pod all set up. Now there is a place to input the ranges, there is an option to have the ticks scale automatically or have them labeled every x, where the user can input x, and there is a place to choose if you want trig functions to graph in radians or degrees.
The inputs for the ranges and the scale are all parsed now, so the user can put in 2pi, or 3/2, things like that. I did notice though that the parser doesn't work for anything that has a negative number and then an operation that isn't +, -, /, *. ie -2pi and -3.2 don't work.
Now I am in the process of working on getting the scales and trig functions to actually graph properly. :)

Monday, September 12, 2011.

Working on graphCalcBrain.
I've gotten the different factors for zooming all working from the menu now. As far as I can tell the menu for the mouse mode is now fully functional, and the text is changing according the the mode, so I got rid of the mouse mode button and rearranged the existing buttons a bit.
You can now click on the menu or click on the other pods without the calculator interpreting that as a click on the graph (ir if you're in zoom mode, clicking on a different mouse mode from the drop down menu which overlaps the graph, won't make the graph zoom in).
I noticed that the "locate" point defaults to yellow, and even though you can change the colour from the colourPicker and it works, the colourPicker defaults to blue. I tried to change that colourPicker's default colour to yellow as well but it seems to be stuck on blue. So I changed the point's default colour to blue so they match up when it first shows up.
Now I am working in a big overhaul of the Domain pod and how the graphs (especially trig functions) are graphed.

Friday, September 9, 2011.

Working on graphCalcBrain
I've gotten all the mouse modes working properly now. The factor zoom had been zooming, but it seemed to be focusing on random spots. So now it will zoom in and out centered on where the user clicks.
I've also got the graph's labels redrawing correctly when different types of units are selected.
(Side note: should the option for radians maybe say "rad" instead of "pi"? Since "rad" is what kids would be used to seeing on regular calculators already.)
Although the axes are redrawing, the functions seem to be behaving weirdly. I'm not sure how a polynomial functions should graph when the axes have different units, or how a trigonometric function should graph if both the axes are degrees or radians. But trig equations don't seem to be working even with the right types of units so I tried going through all the functions that graph the equations to figure out exactly how it's being done. I tinkered with it a bit but it still isn't quite working.
I also created a menu and moved the mouse modes up in there instead of a button. I tried to write it so it is easy as possible to change back to the button if that turns out to be better. So far all the mouse modes work when you chose them from the menu except for the factor zoom; I'm still working on the submenu.

Thursday, September 8, 2011.

Working on graphCalcBrain.
The rectangle zoom is working now.
The user can drag a rectangle on the graph, in any direction, and then the space in the rectangle becomes the entire graph. The graphs are redrawing correctly and is working in all the quadrants.
I have a zoom out button that is also working.
Rather than keeping track of what the previous graph looked like and reverting back to that, instead I decided to keep track of how much the graph shrunk and then just increase it by that much again. I did this for the case when you zoom in, then pan, then zoom out again. I figured it made more sense to zoom out and stay centered at the same place rather than zooming out to a different spot.
As far as I can tell the rectangle zoom is functional, but I'm sure I'll be able to play with it a bit and find something to fix. Other than that the only mouse mode left to fix is the factor zooming. Then Ross and I also talked about changing some of the pods to menus to make it look nicer.

Wednesday, September 7, 2011.

Working on graphCalcBrain.
I fixed the problem that the top left quadrant was the only one working. Now the entire graph is functional for all the mouse modes, even after moving and/or resizing the calculator.
The pan mode seems to be working except for two things I couldn't figure out how to fix: the "0" for the number lines showing up in weird spots.. I know the parameter for ubNumberLine2 that needs changing but I dug around in ubGraph for where it creates the number line and it is in some helper I can't find. The other is the axes floating off the calculator when panned.
The locate mouse mode seems to be fully functional now though. Before, the point it gave you wasn't right. I could see in the code that it was trying to convert the pixel coordinate to the graph coordinate but I wasn't sure exactly how so I just did that mostly from scratch again and it is working now. The dot is also showing up in the correct place now as well.
Next mouse mode I am tackling is "rectangle" zoom. So far that mouse mode doesn't do anything, so I am going over all the code I wrote last work term and trying to fit it in here.

Tuesday, September 6, 2011.

Working on graphCalcBrain.
It is nice to be back after the summer. :)
I am picking up again on the graphing calculator.
A bit of a slow start; getting familiarized again with the code and remembering exactly what is going on. (Looks like someone cleaned it up quite a bit from what I remember though).
What I was trying to work on today was the different mouse modes. They were only working for the top left quadrant. I noticed that to figure out whether or not the mouse is on the graph it checks the location of the mouse, but this wasn't lining up with the graph. I changed them temporarily so that I could look at other problems with the mouse modes, but when I think will need to happen is some globalToLocal() stuff so that the coordinates of where the mouse is, is with respect to the graph. Right now there are so many layers I'm not sure what the coordinates are with respect to, but once I dive into it and figure out what all the layers are and what they're called I think I can fix it.
For the "locate" mouse mode I noticed that it was not giving the correct coordinates. I think I am going to try to fix that from scratch because there are a few places that I think it would be useful to be able to take a mouse position on the graph and get the corresponding graph coordinate. So I've been going over how the graph is built so I can understand how to tackle that so it works even after zooming or panning.
I think I have a much better idea of how the graphing calculator is working now and can tackle the mouse modes!

Wednesday, April 20, 2011.

Working on ubSkipCountingTool.
All of the code for the zooming is in the .as file now, just it was first written on the stage of a specific tester, and now it needs to be tweaked to be a mouse mode in the menu, so most of it is just commented out and I am fixing a bit at a time. When in the zooming mouse mode you can draw a rectangle on the stage and a pod appears with the correct zoomed image in it. All the buttons are on the pod, they are just not totally functional yet. I've changed the scope/parenting in most of it, there are just a lot of small things that probably need to be changed to get it to work properly. I spent a lot of time just trying to figure out how everything was working and now that I am more familiar with the ubSipCountingTool class I'll be able to get a lot more done tomorrow.

Tuesday, April 19, 2011.

Working on ubFractionSquare.
I forgot to update Monday since it was all hectic trying to get flash to compile again! Reinstalled a few times, and lots of other stuff, but no luck. Crystal came over to fix it (also with no luck) and I worked on her mac for a while.
Today whenever I needed to compile I would commit the .as file and Crystal would tell me if she got any errors (surprisingly, not all that much slower than it would take this computer to compile anyway!) So I fixed some of the zooming weirdness by making the zoomed piece centered over the square rather than the mouse (which looks better too), but there is still some other stuff happening that I can look more closely at tomorrow when I use the mac again so I can actually look at traces. The pieces also don't get stuck behind the duplicates anymore when you drag after I figured out why floatToHighestDepth wasn't working. I also fixed some of the pod issues that happened after resizing the pod and then trying to add wholes. There is still some other pod stuff happening, but again I will be able to tackle it better when I can see traces tomorrow!

Friday, April 15, 2011.

Working on ubFractionSquare and ubSkipCountingTool.
I spent a while continuing to fix errors in ubSkipCountingTool, but then flash decided it didn't want to compile anymore, so every time I tried the whole program crashed. I spent a while trying to get that to work but it looks like I may just need to reinstall it on Monday.
So I spent the rest of the day doing things that require no compiling. I zen doc'd ubFractionSquare, adding the verbose parameter everywhere, as well as changing all the podName_mc.movieClip_mc to podName_mc.getInside().movieClip_mc. This is messing up some parenting for the mouse events of buttons on the pod, which I went through and fixed to the best of my ability at the moment but it's hard to tell if I got it all since I can't compile! I also did some parenting changes in ubSkipCountingTool, which I can also go through and check more thoroughly once I get flash working properly again!

Thursday, April 14, 2011.

Working on ubFractionSquare and ubSkipCountingTool.
I working a bit in the morning on ubFractionSquare, got the pod resizer working correctly, and all the bugs on the WIBNIs list are fixed!
Then Ross and I looked through ubSkipCounting tool and added in the zooming stuff that I wrote. So I went through everything that I wrote, changing the scope and moving around functions to get it to (hopefully) work in the .as file, as I had previously just written it in a tester. Clearly this made a ton of errors so I've started compiling and going through all the errors and fixing what I can.

Wednesday, April 13, 2011.

Working on ubFractionSquare.
I've worked some more on the undo/redo stuff and now the undo stack is being built properly, it records a new state whenever the user adds a new duplicate, moves an existing duplicate, resizes, or moves a cell (but does not record if cell ends up in the same place). I also changed how things were not allowed to overlap since it didn't work very nicely, and now instead things can overlap as you drag, but the mouse events get turned off while that's happening so that cells don't zoom by accident, and cells don't get stuck under each other. I will later be adding a grid so that if tables are overlapping when they are placed on the stage the table will move to the next available space.
As you drag around a duplicate I've gotten it to float to the top so that it drags over top of any existing duplicates. The resizer is fixed, so that it won't trigger the zooming on other cells, and there is no longer a space beside the button that also activates it. And now you can't exit the builder pod, since there would be no way to get it back if it got closed.

Tuesday, April 12, 2011.

Working on ubFractionSquare.
I've got it working so none of the clones can overlap, but I'm not sure I like it very much. If the user puts fractions all around the pod and doesn't leave room then they can't drag another one out and it can be a little annoying. Another way I could do it is to turn off all the mouseManager stuff while anything is overlapping and if they drop a square ontop of another then move it. If that would be a preferred solution let me know and I can change it.
I fixed the zooming issue when it was calling the functions in a funny order so it wasn't working correctly. I needed to put in some variables to keep track of what was going on and then add an extra call to the function that zooms the piece if it is necessary.
The zooming is turned off now when dragging anything around the stage so that it doesn't get triggered by accident.
There is an onReleaseOutside type function so that the duplicates don't get stuck to the mouse anymore when you drag them, since when you try to drag one on top of another the mouse can move outside of the movie clip.
Then I started working on undo/redo again. I have it picking up the state and adding it to the undo stack when the user drags a fraction onto the stage, moves a duplicate, and moves a cell. Right now I am trying to also get it to recognize if the user did one of those things but didn't actually change the state (like if they picked up a cell and dropped it in the same spot) so that you can't undo and nothing changes.

Monday, April 11, 2011.

Working on ubFractionSquare.
The different fractions can no longer overlap. The dragging is restricted for the original square being dragged off the pod as well as for duplicates already on the stage. It also restricts the resizing if squares start to overlap.
There were some zooming issues that Crystal posted a video for, but I can't recreate the glitch so I think I may have unintentionally fixed it while I was changing things with the cells and zooming before.
There was also a weird problem where the cells would lose their colour and everything would turn white, and that was because I had spliced out black from the crayola colours array, but not white. So without white in the set of available colours that seems to be working.
Another thing that was happening with the zooming is that if two cells are adjacent and you roll off of the first onto the second, the zooming stops working until you roll off of the entire square and back on. I found out that this is because the RollOver for the second cell gets called before the RollOut for the first, which kills the timer and thus the zoom never happens. I'm not sure why it's getting called in that order but I am brainstorming a fix!

Saturday, April 9, 2011.

Working on ubFractionSquare.
The pod resizer was not working and would shrink the pod whenever you tried to resize it, but there really wasn't any reason to resize the pod so I made the pod size nonadjustable. This may even be better since the user has to drag the duplicate OFF the pod for it to work, and if they can make the pod bigger they may try to drag the clones within the pod and that wouldn't work.
The two set of option buttons ("Build" "Clone" and "Yes" "No") both have one word appearing bigger than the other. I tried playing around with the ubFramedText properties but I can't get them to be the same size. I'm not sure why.
I've made the warning pod float to the top depth whenever it appears to that it doesn't get stuck underneath any duplicates on the stage, and I've fixed the text on the pod, which was getting cut off and wasn't the right font, as well as center the pod over the builder so that when it appears it gets in the way of what the user is doing so they don't try to continue building.
Now I am trying to make it so that when you drag a fraction square around it can't overlap with any other fraction squares. This is kind of weird and tricky but I think I have to basis of it down and I will just need to keep tweaking it until it works, but then the duplicates won't get their mouse events confused when they are placed on top of each other, which is what currently happening.

Friday, April 8, 2011.

Working on ubFractionSquare.
I've put a pin in the undo/redo stuff for now to work on the problems Crystal and Agnes found and put in the google doc WIBNIs. Since I only have a couple weeks left it would probably be easier for someone else to put in the undo/redo stuff than fix little quirks. So I've got the issue with the resizing button working (since the fractions stay square when you resize the cursor is rarely on the button when you release and would get stuck). Since the mouse events for the resize button is all in handled by MouseManager, which doesn't have an onReleaseOutside, I made a makeshift one out of MOUSE_OUT and onMouseUp and now that seems to be working. I also made it so that the fraction pod can't be dragged off the tool pod. But since I figured it won't always necessarily be on a pod I have a couple cases so it can also handle being placed on a ubShape (what is up with getBounds? I could not figure out where it was getting it's numbers from!) I'm not sure if it would ever be placed on anything other than ubPod, ubShape, or the stage, but so far that is what it can handle. Many more little fixes and chased geese to come tomorrow.

Wednesday, April 6, 2011.

Working on ubFractionSquare.
After a couple calls from Ross he got duplicateUbMovieClip working again! :) So now I am working on getting undo/redo working for ubFractionSquare. I am looking through how ubSkipCountingTool did it and trying to do it similarly. I've got a method working that returns an object with all the information about the state, from which the stage could be recreated in that state. Now I am going through all the critical things that the user can do (add a clone, resize, move a highlighted piece, move one of the duplicates, etc) and creating the points at which the user can undo something and keeping track of all the states. It's a little confusing but after going through ubNumberLine I think I get how it is being done and how to do it for ubFractionSquare, so I will be working on getting that up and running soon!

Tuesday, April 5, 2011.

Working on ubFractionSquare.
Ross and Crystal and I chatted for a while to figure out what stateArray() should return, and decided it is now getState() and returns the entire state of all the duplicates! So I am working on that as well as all the functions I need to use state player so I can add in an undo/redo button. Now just since cells get move around and I need to keep track of where they all came from I am trying to assign each cell values to remember about itself, but I guess there are some things going on with ubTable right now that is making that difficult (working with Crystal right now to see what is up with that :) ) so I am also going through the list of things Crystal gave me of things she found in ubFractionSquare that are a little weird or broken and I am just going down the list fixing things.

Monday, April 4, 2011.

Working on ubFractionSquare.
Got some broadcasts and methods working! Now that all that breaking/fixing things is over I feel productive again. :) The class broadcasts each time a duplicate is released and gives the instance of ubFractionSquare, and the name of the duplicate that was just released. They can use that name to call the deleteDuplicate() method which will delete a specified duplicate (obviously). There is also a method isSimplified() which returns a boolean that indicates whether or not all the duplicates for that instance of ubFractionSquare are simplified (the cells have been dragged to fill up as much as possible). Then there is the stateArray() method that will return an array with the values of all the fractions, but we are still figuring out exactly how that should work, there seems to be about a dozen different ways depending on if we return the whole duplicate (say 2 1/3) or as parts (2, 1/3 or 1, 1, 1/3) and then if fractions that are filled up should be 1 or say 4/4, and if they are from different duplicates should it be 3/4 + 1/4? All very confusing but once the storyboarders decide what they want and what is useful then that method will finished fairly quickly afterward!

Friday, April 1, 2011.

Working on ubFractionSquare.
The fraction square was action weird in the tool container; when the square was dragged off the pod it wouldn't land where it was dropped. I found out this is because the tool had the fraction square on a pod and my tester didn't. So there were a few things that I had to go trough and change from global coordinates to coordinates in respect to the ubFractionSquare instance instead. So I'm hoping that is all working well in the tool container now. Ross also figured out how to make the function not call all the mouse event functions multiple times after the table is resized by tweaking some things in ubTable and ubObject. There was another problem that was happening when trying to drag highlighted cells around but I had a suspicion that that was linked to this problem and it was! So that is fixed too. As far as I can tell the fraction square is totally functional, the rest is all adding methods and broadcasts for the programmer, but just looking at it from the user's perspective I think it has basically all the functionality it needs. :)

Thursday, March 31, 2011.

Working on ubFractionSquare.
Still trying to figure out the resizing problem. From what I can tell the problem is this: normally, when I roll over a highlighted cell, the onRollOver has a setTimeOut that calls another function that zooms in on the cell. Then roll off kills it. So if I roll on and roll off before it calls the function then the time out is cleared and everything is fine. After I resize, when I roll on it calls the onRollOver function once, and then again the exact same number of times as the onMouseMove was called to resize the square (so however many pixels I increased or decreased), and then when I roll off it calls the onRollOut function the same number of times. Then the first time out gets cleared, but for all of the rest it still goes to the zooming function, which obviously is less than ideal! When I resize it I don't create anything, no extra cells or layers, I only setProp("width"..), setProp("height"..) and change the _x. So maybe it has something to do with how ubTable changes the width and height? I'm not sure so in the mean time I just worked on adding in broadcasts and other methods like figuring out how to tell if the student has simplified the fractions as much as possible.

Wednesday, March 30, 2011.

Working on ubFractionSquare.
Zooming is working, and dragging cells is working again. I fixed some weird offset-problems, where things weren't matching up by about 20 pixels. I had a hard time figuring out how to make the mouseManager stop listening to a certain cell rather than all the cells, so that if it turns white it doesn't react anymore, but Ross helped me with that and that is working too. Now what I'm trying to fix is a bunch of weird problems that only start happening after a duplicate is resized.. the cells start acting funny and I think it has something to do with something getting created too many times because after it is resized, the roll over/on press functions get called multiple times instead of just once (but a specific number of times so I don't think it is an onEnterFrame or setInterval problem or anything to do with time). I will look at diving deeper into that and hopefully it will be back to the functionality it had before, which is proving to be harder than I anticipated!

Tuesday, March 29, 2011.

Working on ubFractionSquare.
Chasing more geese! Since I changed everything around a lot of things have gotten lost and so some of the functions don't work. Fixed a couple today though and now the "zooming" works again. On the duplicates the mouse is supposed to be the hand when it's over highlighted cells and the regular cursor when over white cells, but right now it is the hand cursor over all the cells, so I am trying to fix that. Also the highlighted cells aren't dragging anymore and I am working on that as well.

Monday, March 28, 2011.

Working on ubFractionSquare.
Forgot to update on Friday! But I got everything organized, this made a few things not work though so I have just been chasing geese all day! It is almost back to the functionality it had before. The highlighting wasn't working, but it was a global/local issue and is working again. At first dragging the clone wasn't working, it would just drag the entire pod, but that was a startDrag issue and it got fixed as well. All the different mouse icons are working at the right times now too. The duplicates can resize again and it works as it was before, the goose I am hunting down now is why roll over/on press functions for the highlighted cells aren't working anymore. There seems to be a lot of parenting problems so hopefully that is what the glitch is and it can get fixed soon too!

Thursday, March 24, 2011.

Working on ubFractionSquare.
I am still going through my code, separating everything out into the constructor, create method, onLoad, etc. It was all jumbly before and now it's beginning to feel a lot more organized! Although it's taking a lot longer than I expected since I have to go through and change A LOT of parentage. This is also giving me a chance to better comment my code so I'm doing that along the way too. Spent some time talking with Crystal today and she explained some of the magic things that flash does and now I am less confused about how classes work, (I think!) Then when Greg is done playing around with ubSnapShot I'm going to work on making a different progress bar for the camera. It's hard to explain what I'm doing since I'm not actually changing the functionality of ubFractionSquare right now, just fixing up all the behind the scenes and zendocs things! I think I should be done with that soon and I can get on to adding in more broadcasting and more methods.

Wednesday, March 23, 2011.

Working on ubFractionSquare and the camera icon.
Crystal was helping me with some broadcasting stuff and noticed that the way I had my class and constructor set up was wrong. So I started, but haven't finished, going through my code and tediously changing a lot of small things! That will continue on tomorrow.
As for the camera icon, I made it so that when you click the camera icon, a bitmap of the whole stage appears at the top level, and disappears after you choose the check or x button. However after playing around with it, the problem is that even though there is a bitmap on top of the buttons and anything clickable/draggable, you can still click and drag those things, but just behind the bitmap, so you can't see what you've done until the bitmap goes away. The whole point of trying to use a bitmap was so that we didn't have to worry about disabling buttons and stuff, but since the bitmap actually doesn't help that problem, maybe the whole idea of using that is pointless since it looks like we would need to disable all those things anyway? I tried to play around with it but my laptop decided to take a good 3-5 minutes every single time I tried to compile, so I didn't get very far. Hopefully it will be in a better mood soon.

Tuesday, March 22, 2011.

Working on ubFractionSquare.
The parameters for the fraction square are now in an initObject, and it is still working how it should. I also fixed the colours so that when you drag a duplicate off the pod it runs through all the colours before reusing any, so two in a row will never have the same colour anymore, which was happening before. I think the tool itself is basically working how it should other than a few extra parameters I may add, like either letting the duplicates land wherever they are dropped (which is how it's working now), or having a sort of invisible grid so it snaps to the grid. That may be tricky since the squares can be resized, but I will think about that more later. So now what I will be working on is adding in broadcasters, which I am doing now, and thinking of methods which would be useful for this tool, such as letting the programmer dynamically delete a duplicate. I am also trying to go through what I have written and clean it up for whoever will need to read through it in a couple months when I am gone! :)

Monday, March 21, 2011.

Working on ubFractionSquare.
During the flashfest and today I've gotten the fraction square tool working a lot better. Now the highlighting and the background of the fraction change colour when it's dragged off the pod, which looks a lot better. The MouseManager is working so that the user can drag the fraction around again once it has been taken off the pod, and all the things you can do with the highlighting still works at the same time. I've also added a parameter in the create statement so that when a highlighted piece is dropped onto another fraction square it can either snap to the cell it was dropped on, or to the next available position, filling the square from top to bottom and left to right. You can now also resize the fractions. Once one is resized, it simultaneously resizes all the other fractions on the stage so that they all stay the same size. And the fractions always stay squares (or proportional, if there are wholes) as the user resizes. There is also a parameter in the create statement for the smallest allowable size of the squares while resizing. I also changed a few small aesthetic things like lightening the arrow buttons when they aren't usable, etc. I probably should have updated this before the weekend because I know there was more but I am drawing a blank right now. But it is coming along pretty well, I think!

Tuesday, March 15, 2011.

Working on ubFractionSquare.
I changed the clone mode so that when the user drags a fraction square off of the pod, the highlighted part changes to one of the crayola colours, so when they move the cells around they can see where the cells came from and colour code as they'd like. When the cell zooms out if they hover over it and when they move the cells to different places they all stay their respective colours. The dragging cells is now working again because I started using the MouseManager class for the onRollOver and onRollOut functions for the parent of the fraction squares. Now when the user is over the grey background of the square, the cursor turns into a multidirectional arrow and this should indicate that the user can drag to move the location of the entire fraction square and any wholes that are attached to it. I am having some trouble with the dragging right now which I am going to play with a bit more and then maybe get some help with it tomorrow at the flashfest!

Monday, March 14, 2011.

Working on ubFractionSquare.
Fixed a few weird things that were happening with the building mode and highlighting/adding cells and columns, and that seems to all be working. So I had it working that you could drag highlighted cells to other cells, and today I changed the cursor when the mouse is over the background so that the whole clip can be dragged.. but that seems to have overridden the onPress/onRollOver stuff for the tables themselves, and I have been trying to figure that out and get them to both work. I took a bit of a short day this morning, but I will work on this more later today when I am not feeling so jet lagged!

Friday, March 11, 2011.

Working on ubFractionSquare.
I figured out why the "zooming" of the cells weren't working. Since there can be any number of cells, I was creating the onRollOver functions in for loops, which seemed like it was working but actually wasn't. So I had to do basically the same thing in a very long, tedious, round about way because flash is weird! But that is working now! The users can now also pick up and drag a highlighted cell and move it to an unhighlighted cell (as long as they are equivalent fractions). If the user places the cell somewhere inapplicable (just somewhere random on the stage, over an already highlighted cell, or on a cell of a different "size", then it snaps back to it's original position). At first this was tricky because then the previously, but no longer, highlighted cell would still act like it was highlighted.. but after many traces and more for loops than I know what to do with, that is also working! I plan on adding to the initObj a parameter to decide if when the user drags a highlighted cell it should drop directly onto the cell they placed it on, or if it should fill up in order and snap to the next open cell in that table.

Thursday, March 10, 2011.

Working on ubFractionSquare.
The cloning mode is coming along very well! I have the hand cursor working when it is supposed to. When the user drags a copy off the pod, the background changes to one of the crayola colours, and the original appears back on the pod (still grey). If the user hovers over a highlighted cell on one of the fraction squares they have duplicated, a larger image of that square appears on top of it (in case the squares are too small). Then it disappears when the user clicks or moves the mouse off of the cell. That is generally working, but since the user can make as many copies as they would like, it is getting a little tricky keeping track of everything so a few parts aren't working. So I need to fix that up, and then next will be letting the user drag highlighted cells into unhighlighted cells and manipulate the fractions, as well as move and resize the fractions they have dragged onto the stage.

Wednesday, March 9, 2011.

Working on ubFractionSquare.
I spent the morning working on the clone mode. When in clone mode, all the buttons disappear and a box appears around all the squares, which are then draggable all together, so the user can drag them off the stage. Then I was trying to figure out a good way to duplicate that entire thing so there would be one copy on the pod again, one one to where ever the user dragged it. After a couple hours alone with limited success, I worked with Crystal and Ross for a few more hours on it. We made a ubObject method duplicateUbMovieClip. It's not completely working, but enough for my purposes so I kept working on the clone mode, and can continue with that tomorrow!

Tuesday, March 8, 2011.

Working on ubFractionSquare.
I've added tool tips to some of the buttons, and added more parameters to the initObject. I also got the ubOptionButtons on the warning pod working. Before, the fraction would erase any highlighting if the user adds or removes any cells, but now if the fraction would remain equivalent, the highlighting stays. Now I'm working on the clone mode, so getting however many tables there are on the pod to drag together. And then once they are dragged off the stage, replicating it on the pod again, and letting the user resize all the tables on the stage together. I am also working on changing cursors and just getting things to look as aesthetically pleasing as I can!

Monday, March 7, 2011.

Working on ubFractionSquare.
Oops! I flew out to Oregon late Friday night/early Saturday morning so I guess I forgot to update this on Friday. So Friday and today I got the fraction square working, you can highlight and unhighlight cells. If you highlight and then try to add more cells a warning pops up asking you really want to continue since all the highlighting will be erased. Now that pop up uses ubOptionButton for yes and no, but when I try to unselect both options once they choose (for the next time it pops up), neither mc.unselectAll() nor mc.setSelectIndices([]) work. So right now that is not resetting. If it's a problem with ubOptionButtons I may just change them to regular ubButtons? I was just trying to stay semi-consistent with the cake model. I also added in + and - buttons to add in more or take away "whole squares". The pod grows and shrinks and the existing squares move accordingly to make room or fill empty space. So the whole "build" mode is basically working! Just a couple small things like adding tool tips and I will be moving on to getting the "clone" mode working.

Thursday, March 3, 2011.

Working on ubFractionSquare.
Crystal went over in more detail what she wanted the tool to look like and how it should work, so I had to back track and change a bit.
Now the tool is on a pod, and the user can change the fraction square (adding more rows and columns) and they can highlight cells in that square. Since adding more cells after highlighting is going to reset the highlighting there will be a pod asking the user if they really want to add more cells. There will be a "build" setting and a "clone" setting. Right now only the build setting is semi-functional, being able to manipulate the fraction square, and soon add or subtract "whole" squares. Then the clone setting will let the user drag what they have built onto the stage. So I have lots of work to do on this and there will be lots to come!

Wednesday, March 2, 2011.

Working on ubSlider/graphing calculator and ubFractionSquare
Goose chasing with Ross today! We did fix the problem with the number line redrawing incorrectly, which was the biggest problem. We also figured out the problem with the tick labels showing up in the graphing calculator but not in the tester. We also discovered that sometimes when one of the bounds get changed, even if the current value is still between the upper and lower bound, the program would think it wasn't and would move the current value to the middle. It turned out just to be an issue with comparing a string and a number instead of two numbers, so that issue is fixed. So other than the multiline problem not being fixed in the graphing calculator for some reason, even though it is fixed in the tester, it looks like the graphing calculator is pretty much ready to be shown on Tuesday. And now that the labels are updating correctly now it is easier to see if the pod shrinking and growing with the number of digits in the maximum value is working or not, and it seems to be working fine. Then I got a bit of work done in ubFractionSquare, still working on getting the buttons working properly. But I am very happy ubSlider is working now! :)

Tuesday, March 1, 2011.

Working on ubSlider/graphing calculator and ubFractionSquare.
I worked with Crystal for a few hours on the problems with ubSlider. She did find what was wrong with the parameters button and why it always copied the text from the mode. So that is fixed, but she was also stumped on why the number line wasn't redrawing correctly or why the text field multiline problem is fixed in the tester but not the graphing calculator. So I am glad I'm not the only one who got stumped! After that, she gave me the rough idea for the ubFractionSquare tool, which I started making from scratch today. So far you can create the ubFractionSquare at a user-specified location and size. I have buttons to add extra columns and rows and text fields to show the number of columns and rows. I have been working with ubSlider, but I have never made one from scratch so I was a little slow to start, figuring out how it all worked exactly, but I feel more familiar with it now and I will start on getting the buttons actually working tomorrow.

Monday, February 28, 2011.

Working on ubSlider and skip counting tool.
I've been going through ubSlider, adding in tons of traces to see exactly what's going on and why the number line isn't always redrawing properly. It looks like it should be redrawing properly! So after trying lots of various things I'm still not sure what the problem is. I also kept looking around at php code but it looks like the forum has given up helping me (it's kind of a hard way to get help anyway unless you are writing a very small program and you can share all of your code.. not so easy when you're program is 1000+ lines!) So the two things I have to work on is that one issue with ubSlider and the php stuff, both of which I am feeling pretty stuck on. I can continue to chip away at them but it's going pretty slowly so if there is anything else anyone has that they would like me to work on as well I am up for that!

Friday, February 25, 2011.

Working on graphing calculator, skip counting tool, and ubSlider.
While working on the parameters pod for the graphing calculator and ubSlider, I've found that when I make changes, the slider works differently for the graphing calculator than when I make a small program just with a slider in it for testing. For example the numbers in the text fields disappearing is fixed in the tester, but not fixed for the graphing calculator. Also when I try to change the lineInit in ubSlider, some things work and some don't. Changing the colour of the line will work, but showUnits does not change anything. So I think that may be something to do with ubNumberline2, since that is how the number line gets drawn. And maybe that is why the number line is being so weird because I still can't figure out what is going wrong and why it isn't redrawing correctly sometimes. Despite that, I have fixed the pod now so it grows and shrinks appropriately so numbers aren't hanging off the end of the pod. I was also talking back and forth with someone on that forum again today about the .php file, and he or she got me to try out some things, but it is a slow medium of communication so we still haven't cracked the problem yet. I've also just been looking at php tutorials and stuff trying to see if I can get the hang of it enough to solve the issue myself.

Thursday, February 24, 2011.

Working on graphing calculator, skip counting tool, and ubSlider.
I've got the pod growing when the maximum value is too many digits to fit, but there are some very strange things happening with ubSlider. Sometimes when you update the maximum value, the number line redraws wrong, sometimes it redraws correctly but the original "10" value under the number line doesn't disappear so there are two numbers on top of each other, and sometimes it works perfectly fine. I can't seem to find any pattern to indicate why it sometimes works and sometimes doesn't. I did find though that if you press enter and it doesn't work, if you then kill focus by clicking on another text field it will redraw the graph correctly. So I filled ubSlider with traces to figure out what is going on and no matter how you update the maximum value (press enter, press tab, or kill focus by clicking somewhere else) it all calls the exact same function, so I have no idea why that isn't working only sometimes and gave up for the day once my brain couldn't look at it anymore. So I fixed a few other small problems like the number disappearing in the text field, that doesn't happen anymore, which looks a lot nicer. I also found a php forum and posted my problem there and got some feedback. As was suggested, I installed FireBug to help see what the problem was and it looks like it may have something to do with the variable not being passed to the php file from flash correctly. So I have been talking back and forth with some people on that forum about it and although it isn't quite working yet, as soon as this one problem gets figured out, being able to save the zoomed image in the skip counting tool will basically be working,

Wednesday, February 23, 2011.

Working on the graphing calculator.
The zoom out is now working! And as far as I can tell it also works with all the other modes, and doesn't seem to have any glitches when I play around with it anymore. :) I tried zooming out both ways I talked about yesterday, and zooming out to the exact place you were before, even if you have panned, looks pretty weird and choppy so I have left it the other way; it looks much smoother. I also have the graph updating at the correct times, whether you change the equation or change the parameters, the pod changes right away now (before it only changed when the equations were changed). I also noticed that when the equation was invalid, the box turned yellow, and then white again once the equation is valid, but this was only working properly for the first equation, so now it is working for all three. I am also now working on getting the parameter pod to grow and shrink as the digits to the upper bound grow and shrink, so it doesn't hang off the pod, much like what I did with the text fields in ubSlider.

Tuesday, February 22, 2011.

Working on the graphing calculator.
After trying a few different things, the new zoom is now working! You can drag a rectangle onto the graph (and it can handle any way the rectangle is dragged, top left to bottom right, bottom left to top right, etc), and then the graph refreshes to be zoomed in on the area of that rectangle (not a bitmap so the picture is still crisp and new axes and scales are drawn). It also works with the other modes, so you can pan and then zoom in, or use the other zoom and then this new zoom, and it all seems to work! :) Just now the only thing it can't do is zoom out again, so I am going to keep track of all the previous levels of zoom, and add a button (unless anyone objects and thinks I should use something else?) to go back. Right now I was thinking that if the user say, for example, zooms in on a section and then pans, and then presses the button to zoom back out.. it can either try to keep track of how much it zoomed in before and zoom out that amount from the spot it is looking at, or it can keep track of where it was zoomed in and zoom out to the spot it was at before it panned. I thought maybe the first way made more sense so I've started doing it that way, but I've left it easy to change if the other way ends up being a better choice for some reason I am not thinking of.

Friday, February 18, 2011.

Working on ubSlider and graphing calculator.
The text fields are working more smoothly now, whether the user changes the value or it gets changed automatically, the text fields do not overlap.
I also restarted the zoom on the graphing calculator, since the idea of how it should work was changed. Before the user clicked a spot on the graph and a pod would appear with a zoomed in image of that spot, similar to the skip counting tool. Now the user can drag a rectangle (and I got it to work no matter which way the rectangle is dragged, not only if the user drags from top left to bottom right) on the graph, and (once it is working) the whole graph should get replaced with a zoomed in image of that section. For some reason though, I can't get the new bitmap appearing on the graph, even though it was working when I attached it to the pod rather than the graph. So I have been playing around with getting that working. I was also looking through the code to find where the values underneath the sliders in the parameters pod get added but couldn't find it. I also couldn't find where the text for the parameter pod field/button is added since it needs to be changed. I am also now looking into getting the graphs changing when the parameters pod is changed, not only when the equations are changed.

Thursday, February 17, 2011.

Working on ubSlider.
I've gone through and deleted tons of unnecessary code, found where functions were getting called multiple times and fixed that. So now the pointer stays on the number line even if the max/min values are changed to something that doesn't make sense. Also I noticed that if you change the max value to something larger than 10 then you can drag the arrow off of the number line, but that is fixed now as well. Now I know that in the graphing calculator there are numbers indicating the values of the ticks that needed to be smaller, but that isn't actually part of ubSlider, those numbers must have been added in somewhere in the graphing calculator so I will hunt that down some time to try to fix that and the problem with those numbers floating off the pod a bit if they get too many digits. For the text fields, I made it so they move as the user inputs numbers that have many digits, and move back as they change the numbers to have less digits, and that works well, it only gets screwy when the user inputs something silly and the numbers get changed automatically. So now I am working on trying to get that changing more smoothly.

Wednesday, February 16, 2011.

Working on adding zoom to the skip counting tool.
I am working with PHP, trying to make it possible to save the image on the pod as a jpeg. I have a setInterval which fills a LoadVars with the pixel information, then I use LoadVars.send(..) to send that information to the PHP file. This wasn't working because I thought that flash would go through the entire setInterval and move on to the next line of code after it reaches a clearInterval, but apparently that isn't the case. So a window was opening but it was blank because the LoadVars I was sending was still empty. So I moved the LoadVars.send line to be called only after clearInterval, once the LoadVars has all the information, but when it is there, no window opens at all. I'm not sure why that is since when I trace the .send statement it returns true. So then I tried using a while loop instead of setInterval and now a window does open after the LoadVars has the information, but no image appears, the window is just blank. It seems to be finding the PHP file, but I guess something else somewhere is not working. As I try to figure this out I may start working on ubSlider again in the mean time.
*Edit: Greg took a look at the .php file since he knows PHP better than I do and will get back to me tomorrow. So I am working on ubSlider, fixed the default problem with the borders, and now I am going to try to change all the other aesthetic things about the pod we talked about in the meeting.
I fixed the problem where if you change the max or min so that the current value is not within that range, the pointer does not fly off the line anymore, it gets set to the middle. There was actually code in place to do that, but I've found that when one function gets called, it calls a few more, and those functions call a few more, and a lot of functions end up being called multiple times to get one thing done, so it's right the first time, but then it doesn't get done right the second, or third, or fourth time around. So I am dedicating a good chunk of tomorrow to a giant code clean up. Should be fun!

Monday, February 14, 2011.

Working on adding zoom to the skip counting tool.
Right now I am trying to let the user save the image on the pod. I've added a "save" button to the pod (which now has five buttons so it is looking a bit cluttered, so I was playing with the idea of having the buttons float just outside on the edges of the pod, which looks ok too, and other ways to try to arrange them that is a bit more aesthetically pleasing). Since I am new to PHP, and exporting data from flash to PHP, I've been looking around at lots of forums and checking out people's examples of how to do it, and I get the general idea. I have all the code in place which I've gathered that I need but it isn't working quite right yet. I know it is sort of working because a new window opens, where the image should be, but the image isn't there. So since this is all new stuff to me I will be digging through each line looking for exactly what is happening, and then when I find what is going wrong it should be good to go!

Sunday, February 13, 2011.

Working on adding zoom to the skip counting tool.
I now have it working so that you can move the pod on any level of zoom and the ticks still work. Instead of drawing the ticks directly on the pod, I drew the ticks on the stage before the bitmapData is taken, then hide them after, so they don't actually show up on the stage. Although I found it looks a little funny when I do it this way. I draw the ticks in a for loop, so they all get created with the same line of code, so they should all have the exact same width, but they show up all with slightly different widths and I'm not sure why. But other than that, it is working! I'm not sure how exactly these new ticks should work with the ticks that can already be added by the fractionOpTool though. I've also added two more buttons to the pod so the user can add and subtract the number of ticks between each whole number. Since the pod is not necessarily very big, I didn't want to take up too much room with these buttons, so right now, as soon as the pod opens they can play around with the number of ticks, but if they then zoom in the buttons go away so they can have more room to see the picture, and then if they zoom out again the buttons reappear.
While I was playing around with the program, I saw a couple strange things happen, but then when I tried to recreate them in order to fix them I couldn't get them to happen again! So now I am going to look into PHP and see if I can get it working so that the user can save jpegs of the picture on the pod.

Friday, February 11, 2011.

Working on adding zoom to the skip counting tool.
Right now I am working on trying to get the extra ticks to work when you zoom in and then move the pod. I thought this might not be working because it coordinates where to draw the ticks on the pod by looking at where they are in the rectangle on the stage, and that rectangle didn't line up exactly right when you zoom in, which wasn't really a problem before. So I looked into why that was happening and fixed that and now it does line up exactly with the image on the pod, but that didn't seem to be the problem. And as I did that I got sidetracked into making tons of variables for things I had previously just assigned a value to while I was getting it working, and then going through and changing all the values to variable names. Whew! Just looking at the code and going through what I think it should be doing, it looks like it should work, but it just doesn't. So after lots of trial and error today and lots of ideas that didn't work, I think I have an idea for how to make it work that doesn't involve drawing on the pod, so I am going to try that on Sunday and hopefully get that working!

Thursday, February 10, 2011.

Meeting most of the day!
Working on adding zoom to the skip counting tool for the rest of the day.
The user can still draw a rectangle to indicate the shape and size of the area they want to zoom in on, but now that rectangle automatically snaps to be vertically centered on whichever number line it is closest to. As the user moves the pod, it can only go left and right as far as the number line goes (although if they update the number line to make it shorter or longer I don't think I can update the pod's dragParametersArray to let the pod move farther). The user can also now move the pod vertically, but this does not change the position of where they are zooming in. Now I am working on getting the ticks to work correctly if the user zooms in and then moves the pod (right now it only works when you move the pod when it is zoomed out as far as it can go). I feel like this will be tedious!

Wednesday, February 9, 2011.

Working on adding zoom to the skip counting tool.
I now have the program working so that for either (or both) of the number lines being zoomed in on, any full unit that is in the picture gets new ticks appearing in the pod. I have it working with the zoom now as well, so the user can zoom in and out and the ticks stay in the right place and zoom properly along with everything else.
I also went through and fixed some minor things that weren't working properly and it's a lot less buggy now.
I have the ticks working when the pod is moved as well, the ticks stay where they were relative to the picture, rather than relative to the pod. And if the pod is moved too much the ticks disappear rather than run off the pod, and ticks on the new part of the number line appear.
*Edit: Just talked to Ross and so now I am starting to work on a few changes:
-change it so that moving the pod left and right moves the spot being zoomed on, but you can move the pod up and down just to get it out of the way without moving the zoomed area up and down
-center the area the user has zoomed in on to the number line
-work with the ticks the user can add to the number line and can highlight if the hop lands directly on a tick.
Also, the line segments are working a bit better. They are still sort of laggy when the pod is moving if you move to pod too quickly, but now when the user stops moving the pod it all snaps into place.

Tuesday, February 8, 2011.

Working on adding zoom to the skip counting tool.
Since startDrag was getting overridden by ubPod's own drag stuff, Ross added a new parameter in ubPod and now restricting the pod to moving horizontally is working. When the pod moves, the line segments move as well to keep the outline on the stage and the pod connected, but they don't move as smoothly as the pod does now that the outline moves as well, (when the outline was stationary it looked fine, but now it looks like the lines lag behind a bit). I'm not sure if that's something that can be fixed or not.
I figured out how to map pixels from the stage to the pod, and now I am in the middle of working on being able to get the stage coordinates of certain places on the number line which would be important for redrawing things on the pod. So I have been reading through the ubFractionOpTool code to see where/how things get drawn and such, so I can redraw more ticks between existing ticks.
To start I just tried adding ten ticks between two existing ticks when zoomed in on and that is working; the ticks are showing up in the right spots (yay!). Next I need to try to get this to work smoothly with zooming in and out and moving the pod, because so far they just sit on top of the moving image on the pod and do not change.

Monday, February 7, 2011.

Working on adding zoom to the skip counting tool.
The outline and line segments are working. The lines are in front of the stage, but behind the pod. The lines move as the pod moves and they also move when the outline grows or shrinks as the user zooms in or out. The user can also zoom in and out without the line segments appearing in the picture.
I made the pod appear directly above or below the section of the stage that is being zoomed, and made it so the pod can only be moved horizontally. As the pod gets moved horizontally, the section that is being zoomed in on moves left or right with the pod. And zooming in and out still works after the pod has been moved. To restrict the pod to moving horizontally, I just reset the y coordinate of the pod in onMouseMove. This works, but doesn't look very smooth. If you try to move the pod vertically it gets jumpy. Maybe there is a better way to do this?
Also at first when the user dragged on the stage to draw the rectangle that will be zoomed in on, it would only work if the user dragged from the top left corner to the bottom right corner, but now I have it working no matter which direction the rectangle is drawn.
I am still looking for ways to save a bitmap as a jpeg, but as far as I can tell this is not possible with flash alone in AS2. It is possible with AS3, but to do it with AS2 it looks like you need another program, PHP, installed. I'm not sure if that is feasible or not but if it is here is an example I found:
Now I am working on trying to find a way to map pixels on the stage to pixels on the pod, which will make being able to draw on the pod much easier.

Friday, February 4, 2011.

Working on adding zoom to the skip counting tool.
I already had a zoom started in this, but it was just rough stuff while I was playing around and learning how to use BitmapData.
I wasn't sure if I was going to be able to let the user draw a rectangle on the stage and have it zoom in on that section because of the sizing issues BitmapData has, but I did get that working. So now the user drags on the screen, and when they let go a pod pops up with that section of the screen, zoomed in, and they can then zoom in farther and zoom out on that pod. The only issue is that when you drag on the stage of ubPod it highlights the inside of the rectangle it creates, and so BitmapData is grabbing the highlighted image. Maybe I can fix that with some sort of time delay?
Ok the highlighting issue is fixed, now as the user drags on the stage, a rectangle is drawn so they can see which area they are zooming in on. Once the user stops dragging that section gets put in a pod. As the user zooms in and out of the pod the rectangle on the stage grows and shrinks accordingly so it matches the image being shown on the pod. Now I am starting to add the line segments again, but I am still having trouble getting the lines to be behind the pod. And then I will work on getting the lines to move as the pod moves.

Thursday, February 3, 2011.

Working on adding zoom to the graphing calculator.
So now I have that the outline of the zoomed area on the graph shrinks and grows as the user zooms in and out. I am also working on adding line segments from the corners of the outline to the vertices of the pod now, so I am figuring out localToGlobal, and trying to get the lines on the correct layer so that it is above the calculator but behind the pod. Also I am trying to make the lines move correctly as the pod is moved.
It is midday right now and I found out my credit card info has been stolen and someone went on a shopping spree with it so I need to go down to the bank and police station before they close, but I will come back and work on this more after I get this all (hopefully) sorted out!
*Edit: All worked out! :) It was a little tricky getting the lines to appear in the right place, figuring out what coordinates mean what (local and global), but drawLocationButtons helped and now the lines show up in the right spot! Yay. And I am in the process of getting the lines to update and move when the pod moves. So far it looks pretty cool I think!

Wednesday, February 2, 2011.

Working on adding zoom to the graphing calculator.
First, I finished adding the syntax pod, which I have appearing whenever the user tries to enter a variable name they can't use.
Then I fixed up a few things about the zoom pod. At first, a pod would show up every time the user clicked the graph, so I made it so that the pod could only open once, just while I got the pod working. Now that it is working I went through and made it so that a second pod couldn't open if one was already open, but if they close the pod they can click on the graph again to zoom in on a different section of the graph. This is nested in about a million if statements so it was tricky figuring out exactly where everything belonged to make it work properly, but it is working now!
Also when the user clicks somewhere to zoom in, the area that is being zoomed in on (on the original graph) gets highlighted by a box, and I am working on creating line segments that go from the corners of that box to the vertices of the pod (which is trickier than I thought it would be since the pod can be moved, so I would want the lines to move along with the pod).

Tuesday, February 1, 2011.

Working on adding zoom to the graphing calculator.
I have the zoom itself working. Wherever the user clicks is the centre of the zoomed image, unless they click too far off to the side then I got it to compensate and move just far enough in so that it is only zooming in on the graph and does not have a bunch of white space on the side.
I have also started making an extra pod which will pop up when the user enters a variable name into the parameters pod which they shouldn't (ie e, or sin).
I am also still researching and reading forums to try to find a way to save the zoomed image as a jpeg, and still brainstorming some ideas about how to add in new ticks and numbers to the zoomed image and get them to be in the right spot. I have been playing with it but haven't gotten far, I feel like it may take a while and I think I may have to end up cheating: if they have panned the image first, it pans back to the original image before zooming, or something like that. I'll see what I can do!

Monday, January 31, 2011.

Working on adding zoom to the graphing calculator.
There is already a zoom that zooms in on the middle, but this zoom will zoom in on a specific spot and will open in a pod. The other zooming mouse mode is called "zoom", and for some reason I can't have the word "zoom" at all in the new mouse mode or it assumes it is the first zoom mode. So for now I just gave it a dummy name until I sort that out.
I added the zoom, after figuring out the parentage and where everything lies in the code. When I was making the zoom before in the skip counting tool it just zoomed in on a specific spot, but now in the calculator I got it to zoom in on the graph wherever the user clicks.
I have the zoom in and out buttons on the pod, and I am trying to come up with the best way to convert the pixel (x, y) coordinates into the graph (x, y) coordinates for adding in extra ticks and numbers to the zoomed in image. This may turn out to be very tricky since the user can pan the graph first. So I need to figure out how to tell where everything is on the picture so I can add in the new numbers and ticks in the right place.

Friday, January 28, 2011.

Working on BitmapData for zooming.
I haven't gotten very far today so I am going to write out all the things I have tried here so I can refer to what I have already tried and what doesn't work!
The problem is.. I have to working almost perfectly except for that when you zoom all the way out, the picture is too small. When you zoom in again it works fine, just that one picture is funny.
There is an array of the zoomed in images. The first one gets added when the zoom pod is first created.. subsequent pictures are added as you zoom in farther (ie in the + button).. if you zoom in or out to a picture you've already seen it takes it from the array. Since it is the first image that is wonky and it gets added in a different place, I thought that was the problem. So I tried adding that image to the array in the + button as well, which fixed that one problem but made an even bigger problem: when you try to zoom in again every picture gets smaller and smaller. So now it is getting created outside of the button again.
I tried tracing the size of the images before and after they get added to the movie clip (after they are added they get resized to the correct size), and they are all the size of the pod before resizing anyway, except the first one which was bigger. So I thought maybe it somehow thought it was the right size already and that's why it gets too small when I resize it, so I stopped resizing the images when they are added to the movie clip. This didn't fix the problem at all, it made things even wonkier. (And this is when the first image is added to the array inside the + button, when it is created outside, none of the images need resizing because they are all already the right size and omitting resizing them does nothing). But by tracing, still, the image that is too small still thinks it's the right size. Very frustrating!!
I've tried, instead of getting that image from the array, picking it up from the stage again like the first time (since it shows up correctly the first time), but the same image small image appears.
I've worked a bit more on the zoom pod changing according to changes on the stage and I think once I fix this problem that will be working as well since it basically has the same problem of the picture being too small sometimes.
*Edit: I figured it out!! Took long enough.. So the width and height of a BitmapData is read only, so once it's set it can't change. So I figured out that for in order for it to work, you need to take a square of size x from the stage and stretch the movie clip it's on to size y>x to make it look zoomed. Then you have to take an image of size x again from that zoomed in image and stretch the movie clip to size y. Before that first and second x were different sizes. Since we can stretch the movie clip I thought the BitmapData was changing as well but it's not so it made everything screwy, but now it's working!
I also have the image updating when the number lines are changed. The user can zoom in, change the stage, the picture will stay at the same level of zoomed-ness (lol) as before, change to the new picture on the stage, and the user can then zoom out again and it will zoom out with the new picture (I am proud of that one!) :)

Thursday, January 27, 2011.

Working on BitmapData for zooming.
I feel like my brain got a giant workout today from all the brainstorming I had to do on this zoom tool!!
There is some strange sizing problem that is happening and I think it has something to do with the parenting (since there is so much embedding with pods!) I showed to code to Ross and Crystal so maybe they can help.
After hours of playing around with that I decided to move on and look at drawing shapes onto the zoomed image.
So it is easy to draw shapes onto the image, but I didn't see how that would be very helpful. Instead I got the program to listen to when the fraction tool is changed and pick up the changed image from the stage.
I've got this basically working I think, the only thing that isn't is when you open the zoomed image, zoom in a bit, and then change the stage, I wanted the new image to be just as zoomed in as the user was before (not zoomed out to the original size it is when you open the zoom pod). This isn't working but I think it is because of the same sizing issue as before, so once that is fixed I think that will fix this problem as well.

Wednesday, January 26, 2011.

Working on ubSlider and BitmapData for zooming.
I have the new textInit working. I set some of the defaults to what I thought worked best but I don't know if they should be changed. By default, if no textInit is passed in, all of the labels are static with not borders and all the values are input fields with borders. If a textInit is passed in with type:"input", all of the text fields turn to input except the lower and upper bound labels, which I made to always stay static. This made sense to me but can be changed. Also if no label for the current value is passed that text field is not created, as opposed to creating a text field with a default label. I'm not sure if this is sufficient or if maybe there should be a textInit for each text field (so they could get the text fields of all the values to be input fields but the current value label be static or something along those lines, which right now you can't do).
Tabbing between input boxes seemed to work for me already, but apparently it was acting weird elsewhere so I set the tab index for the input boxes, so hopefully it is working everywhere now.
For zooming, I have the zoom in and out buttons on the pod almost working finally! You can zoom in, and then you can zoom out, but for some reason you can't zoom in again after you've zoomed out.
I thought it was because the pod kept offsetting the image, but I fixed that and it's still being weird so I will need to work on that some more.

Tuesday, Januray 25, 2011.

Working on ubSlider and BitmapData for zooming
The slider was not working in a configure pod and it turns out the text fields weren't being created properly so I fixed that and it seems to be working again.
Now we want the programmer to be able to pass different parameters to ubSlider than before and want the defaults to be different so I have the framework of that set up although it isn't quite functional yet.
For zooming, I've added in buttons to the pod to zoom in farther and zoom out. That is not fully functioning yet either but I've started.
I've also been doing some researching on how to save the zoomed image outside of the program as a .jpeg in AS2. I found lots of code on how to do it in AS3, but I will have to play around with it more to figure out how to do it in AS2.

Monday, January 24, 2011.

Researching BitmapData for zooming.
I spent a lot of the day reading all I could find about BitmapData and all it's methods.
Apparently BitmapData got improved a lot in action script 3.0 and is harder to work with in 2.0 (at least that is the impression I got from forums and googling).
I figured out how to capture an image of the entire stage, although this wasn't entirely helpful for zooming.
But I did eventually figure out how to capture a certain area of the stage and then blow it up for a faux zoom effect.
I'm not sure exactly what this is going to be used for but the zoomed image can appear in a pod so that the original stage can still be accessed while looking at the larger image (otherwise the image is on top of the stage and would have to somehow get removed by the user before being able to access the original stage again).

Friday, January 21, 2011.

Working on ubSlider.
It took a while but I finally got the slider to work when the number line is vertical!
The text also works when it is horizontal or vertical, and all four combinations of the two are working.
There were a few other small things that I fixed and I think I basically finished it today unless there is aesthetic stuff I should play with (except for the current value font size being bigger than the size in all the other text fields, which still baffles me!!)

Thursday, January 20, 2011.

Working on ubSlider.
The text boxes now stretch to fit input, and I also got the text boxes to shift over when the input gets too long so that the input doesn't overlap the other text.
Right now I have it so that the user can input as many digits as (s)he wants and if it is too long to fit on the pod the text runs off the pod.
I couldn't think of a prettier way to do that while still allowing the tiny humans to play around with numbers as big as they want.
Although, I got it so that if the user then erases the input all the text boxes shift back onto the pod as they are backspacing, so that is the most elegant solution I could think of.
If I made everything stay on the pod either the text boxes don't overlap and the user can only input so many digits, or everything gets squished up on one side and I didn't really like either of those.
Also the input text boxes now have a border so that it's more obvious that they accept input.
The current value is still a larger font size than anything else and I can't find anywhere in the code where the text format gets redefined.
Pressing the enter button or clicking outside the text box both work for redefining the current, maximum, and minimum values.
The programmer can now define how they want the text boxes on the slider spaced.
So far I think ubSlider is pretty much working, but only if the lineOrientation is horizontal; I set one vertical and the thumbnail isn't even on the line and the text boxes are just all scattered so I will have to pretty much redo all the set up and changes and everything for a vertical line now!

Wednesday, January 19, 2011.

Working on ubSlider.
When the values on the slider were in ubFramedText, the boxes don't stretch to fit the user's input, so today I changed all the ubFramedTexts to TextFields. This messed up the formatting a bit so I went through and tried to make it look nicer. Also I have to go through all the code and change the calls to the ubFramedTexts to calls that are recognized by TextFields (ie. fieldName_mc.setText("") vs. fieldName_mc.text = "").
I don't yet have the program responding to changes to the current, maximum, or minimum values, but it's getting there.
One weird thing I spent a lot of time on but still can't figure out is that when the thumbnail is dragged I got the displayed current value to change, but when it does, the font size increases. I'm not sure why, but I will keep brainstorming that.
*Edit: If I change the value, or even just click in the text field first and then drag the thumbnail the font size doesn't change.. hmmm.
So far I can't get the text fields to move to the left either. When I changed them from ubFramedText, all the text showed up higher and more to the left. I managed to move them closer to the number line, but they are all still kind of squished to the left. It doesn't look too bad but I think it would look better spaced out and for some reason they aren't moving. Maybe I can figure out how to get them to cooperate tomorrow!
*Edit: Another weird thing I just found with the function enterWasPressedHere(ref: Object){..., all the cases in this function are for the different text fields, but when I trace ref it comes up as input_mc, which is what all the text fields are on, so it isn't doing anything after enter is pressed. Not sure why that would have changed.

Tuesday, January 18, 2011.

Working on ubSlider.
When changing the max/min values in the text box, the change is implemented properly, but when changing the label or the current value, the program acts as though it has entered an infinite loop somewhere.
When looking at the code the infinite loop is nowhere to be found. :(
I have yet to figure out why this is happening but here are some things I've noticed while playing around with the code:
- this problem only happens when there are two or more sliders on a pod, when there is only one slider it works fine.
- when changing the current value, the code calls repositionThumbnail() to change the position of the arrow to the new position that was entered in the text box. However the program never enters this function (or at least the traces never get called), but the arrow does move to the new position anyway, even if I comment out the call to repositionThumbnail().
*Edit: I'm not sure what was going on before but it is going into repositionThumbnail() now. :)
- when creating the sliders on the stage or on the pod, it makes no difference; if there is one it works properly, and if there are two or more they do not work.
I am totally stumped right now as to why this isn't working properly, but I will keep playing with it and see what I find.
*Edit: Yay! Ross helped me for a while and we found the line that was causing the crash; it was when we tried to round the input value and then reset it to the rounded value when snapToIntegers == true. So now we just have a restriction on the ubFramedText so that they can only enter integers (if snapToIntegers == true).
Another thing that could be fixed for this is having the text boxes stretch to fit the number that is entered; right now anything larger than one or two digits gets cut off. But I think that that is something to be dealt with in ubFramedText rather than ubSlider if I'm not mistaken?

Sunday, January 16, 2011.

Working on MiniCalc.
Since there is not much that I can do with the activity I am working on at the moment, I am working on my fall-back project, the calculator.
I am fixing up parts of the graphing calculator right now.
For the beginning of the day I was just reading and familiarizing myself with the code since there was a lot going on already, and also looking up and reading about methods I was not familiar with.
For the parameters, previously only the first parameter was functioning, and now all five work.
I could not get the last parameter to work properly for a while, but then I changed the last parameter from "e" to "f" since I realized the calculator recognizes e as euler, not as a variable, so now the last parameter works as well.
I also working with the parameter's option buttons and now the calculator only uses the active variables (ones which have their option button selected).
The parameters pod now has all the text inside of it (before the pod was too small and there was some floating text at the bottom).
I also worked a bit more on the activity, tweaking some small things like making it so you don't have to click the continue button twice to get to the next scene, and cleaning up unneeded code.

Friday, January 14, 2011.

Working on Cluster 8, CLIP 1, Activity 5.
Yesterday I said Scene 2 was done, but that was a lie! I misread or misinterpreted what was wanted to had to redo a bit, but now it's really done! Promise! :)
Scene 3 has a lot of animation and I would be sad if I did it all and then it all got changed so I am waiting for the final storyboard before I go any further.
Scene 4, 6, and 7 need the skip counting tool to be finished.
Scene 5 is finished.
I spent a lot of the day switching all the ubFractions to ubFractionInputs, which caused quite a headache at first before I figured out that setting the fraction in the action script changes the value, but doesn't change the stage. So the fraction thinks it is one number but looks like it is a different number. That had me ripping my hair out for a bit. ><;
I also hadn't heard of ubWait or ubWaitFor so I had put in all the highlights with movie clips, so I went back in today and changed all the highlights to ubWait.

Thursday, January 13, 2011.

Working on Cluster 8, CLIP 1, Activity 5.
Scene 2 - Finished.
Scene 3 - Waiting for changes.
Scene 4 - Waiting for the skip counting tool to be finished.
Scene 5 - I got the stars to toggle between red and blue, and fixed a few small things like on the 3rd attempt if the rows of stars trail off the page make two columns. As far as I can tell this scene is finished now too. :)
Scene 6 - I added in the frame asking the user to turn their fraction into a mixed fraction. Other than waiting for the skip counting tool again I just need to figure out how to go more smoothly between frames when going back and forth and sometimes skipping frames.
Scene 7 - Again, waiting for the skip counting tool.
Since the activity is almost done (at least as for as I can go right now) I also spent a lot of time today cleaning up my code and adding in more comments so it is nicer, especially for someone who didn't write it, to read. :)

Wednesday, January 12, 2011.

Working on Cluster 8, CLIP 1, Activity 5.
Scene 2 - ALL DONE. Unless we want some animation added. But I have all three frames working, with no glitches as far as I can tell. :)
Scene 5 - Tried to figure out why the stars were not getting deleted by removeMovieClip() for a while, then decided to do a cheat fix by having all the stars created and just hiding ones I don't want rather than creating new stars for each new question. So even though I still have no idea why it wasn't working before, it is working now! And I started trying to make a double click on a star toggle it from red to blue, but don't quite have it working. I will start with that tomorrow!
I didn't get as much done today as I had hoped, but a horrible head cold does not exactly facilitate problem solving, so fixing that star problem took longer than I thought it would.
Hopefully I will be feeling better by tomorrow and I can finish scene 5!

Tuesday, January 11, 2011.

Working on Cluster 8, CLIP 1, Activity 5.
Scene 2 - Fixed a couple weird things that were happening with the barrels.
Scene 3 - Leaving this scene for now since it will be changing.
Scene 4 - Got the images where they need to be. I have all the feedback appearing when it needs to and the buttons working, still need to (figure out how to use and) add in the number line and skip counting tool.
Scene 5 - The answer to the star problem still evades me.
Scene 6 - Set up the first two frames. I have all the feedback and buttons working, corresponding to the input.
Scene 7 - Set up the pictures and have it recognizing when one of the fractions is dragged into the box.
Yay all of the scenes are started! I thought it would be easier to set up each one and I can skip back and forth rather than work on one scene all day.

Monday, January 10, 2011.

Working on Cluster 8, CLIP 1, Activity 5.
Scene 2 - Set up the stage, I have all the feedback and actions happening for all input conditions in frame 1 and 2. I have the barrels cooperating finally. :)
Scene 3 - I have everything working up to the first attempt, need to work on the animation that needs to happen for the second attempt but I was told that what was wanted would most likely change from the story board so I didn't want to get too far into that.
Scene 4 - Just started, got the scene set up and images tweaked.
Scene 6 (which I think is actually scene 5? I need to move it) - Mostly all working except the animation. A weird problem is happening with the stars and my brain needed a break from thinking about it. Will try again tomorrow maybe.

Thursday, January 6, 2011.

Working on Cluster 8, CLIP 1, Activity 5, Scene 6.
I finished all the feedback text and feedback actions (except for the animation) to all the different conditions after the Check Button is pressed.
The feedback text was long so I had to play around to get it to fit in nicely and not overlap with buttons.
I got all the parameters to randomize properly and as far as I can tell everything is working how it's supposed to (text and buttons show up when they are supposed to etc). :)
I am still working on getting the stars to move where and when I want them to but I am making progress.
*I need to remember that if I am concatenating a string to make the name of an object I need to evaluate it before I can use it!! *

Tuesday, January 4, 2011.

Learning the basics today. Made myself a wiki page. :)