Our first lovely discovery of what we were breathing in our house. It has more hair than me!
Also is a picture of what we discovered when we had to redo the seal around the window.
Our first lovely discovery of what we were breathing in our house. It has more hair than me!
Also is a picture of what we discovered when we had to redo the seal around the window.
Every now and then something weird happens that you just have to take a picture of otherwise people wouldn’t believe you.
I’m one of the lucky ones whose wife make him lunch
. Sometimes it’s ham, other times it’s leftovers. This time she was making egg salad. She needed to prepare some eggs so she set a bunch within a pot to boil. When she returned to check on them, … well the pictures should explain it:
Medea free of the tube!
Humbug… it’s been 2 years now. This being my third year as a humbugger. I don’t think I’ll return to Christmas as I had it previously. I think people understand that I will not return the favour and give them a gift if they get me one. The past 2 Christmas’ have been fairly stress free. I have to admit, I rather enjoy it.
I wrote a post about 2 years ago as to why I became a scrooge / grinch. Not much has changed. Although I’m less offended when people spread Christmas Cheer. I mentioned before that I would hold my tongue, well now I shrug it aside like they just insulted my lawn… It’s my lawn, I couldn’t care less. In fact, I feel a little pity for them:
I do not miss that at all.
The only thing I’m a little peeved about still is how Christmas is viewed by Christians and non-Christians. Christians are upset that Jesus is being removed from anything related to Christmas and the non-Christians are upset that Jesus is still in Christmas. Granted there is a group that doesn’t care either way, but this is not about them. I get annoyed when I see Christians putting up a fight or protesting to have Jesus returned to Christmas. If someone wants to celebrate with Santa Claus, let them. It’s not our place to impose Jesus on anyone. In fact, it’s quite the opposite. As ambassadors, we are to abide by the rules of the foreign country we live in and at the same time, live as an example (and a good one at that) of who we really are. Throwing a hissy fit because Santa is more popular than Jesus just shows you’re not being a good enough example of Jesus in the first place…. and the hissy fit adds to that.
Either I’m numbed by what goes on now, or things are not as bad as they used to be. Not with the whole X-mas fiasco. If things are not as bad now, then that’s a good thing. It’s just something I’ve seen before and I haven’t vented about for a while, even if that whole thing is now stale.
Anyway… if the traditional gift giving is for anyone, it’s children. I’m still on the fence as to how I want my children to experience Christmas. However, anyone who tries to make that decision for me can stuff it.
Medea’s first start is a rough one.
So I ran into another issue the other day. I needed to create a function that could be overwritten, then have any reference to the original point to the new one… without redoing everything again… For example:
funk = function() { alert('original'); }
caller = funk;
funk = function() { alert('new'); }
// this will alert 'original'... Not 'new';
caller();
But what if I want to be able to override functions and have those such as “caller” mentioned above, to point to the new function. Such an example would be where the function could be overridden based on what modules are loaded and what are not. But the original function will always be referenced. There is a solution though. It takes a little bit more plus my code below. But it is possible now.
By using funcStorage.js, you can use this code for appending functions, or referencing functions by name instead of their location in memory. Essentially you can run the caller() function and have it execute whatever happens to be associated with that at the time, not what it was when it was originally assigned.
Lets attempt something that’s not just pseudo code. Our issue is we want to reload a custom made file directory. The easiest way is to do a window.location.reload(); call. Lets set that as our reloadFileList() = function() { window.location.reload(); }. But we want to use a fancy AJAX solution. In this case we want to just override the function as the AJAX solution is much better. We can’t just go reloadFileList = ajaxReload; because any function that already references reloadFileList will point to the original window.reload one.
Now let me be clear here:
// I do not mean this.
element.onclick = function() { reloadFileList(); }
// I DO mean this!
element.onclick = reloadFileList;
So the only way before was to go back to all the previous references used for reloadFileList and reassign it the new function. But now with the code I posted, you can do the following.
// You can specify what function the onclick uses
// before it's even created.
element.onclick = funcStorage.call('reloadFileList');
funcStorage.create('reloadFileList', function() { window.location.reload(); });
// Later on, or in another file...
funcStorage.create('reloadFileList', function() {
fileList = getFileList_viaAJAX('url/here');
for( k in fileList) {
// perform actions
}
});
So without redefining the element.onclick, it now uses the new Ajax style instead of the window.reload.
For me, the primary reason is for letting the site function even if the file didn’t download properly, I had a bug in one of my js files, or the user aborted while it was getting another file. I would like the site to still work, even if not completely as intended… essentially graceful degradation or a fault-tolerant system.
There’s more than just this, the class also allows for extending functions instead of just overriding them. If you use the extend method instead of the create, whatever is already defined as the function you want, it will get appended with the section argument.
// You don't need to initialize anything.
// Any call, create, or extend will create the necessary
// elements before they are used.
funcStorage.extend('reloadFileList', function() { // ajax style reload });
// now lets put tooltips with thumbnails on the various files...
funcStorage.extend('reloadFileList', function() {
// the down side is you have to treat each extension as if
// it's its own environment and doesn't have access to the variables
// from the previous extensions.
$(elements).each( function() {
// assign a tooltip with picture inside.
});
});
This will then run both functions sequentially. After doing the Ajax call, it will do the tooltip generation.
Hopefully someone else finds this useful.
Again, it’s: funcStorage.js
Being a soon-to-be father is a little different than being a mother. Not that I’ve experienced both, but at least for me, it’s still a little surreal. But now that the baby is moving more, and significantly, it is beginning to feel a little more real.
It’s funny in a non funny kind of way. I once thought of posting an entry of how my dreams are starting to fade away. Things that might have been attainable several years ago, are no longer because of time or responsibilities. While at the time, I was saddened to see them leave, they fade in comparison to my apprehension to my being a parent now (soon). The complications our child is going through and what my wife has to endure, all I’m concerned about now, is her well-being. It’s tough feeling so helpless when you’d give anything to help out.
We had plenty to be worried about. Major surgery on a newborn’s neck. It affected the jugular vein. It could have been stressful for us, but we felt at peace. Knowing the chain of events from when Pam was found to be pregnant, to the surgery, it gave us peace and confidence that this wouldn’t be the end.
Events of late wouldn’t worry us now.
Just test and build our patience.