hook

How does a program work which gathers data from another (not open source) program?

I play an MMORPG and there exists a third party program that can add things to the game's GUI. It can display your HP as a number (as opposed to the green bar), display how long until a power recharges, and other such nifty things. What I can't understand is how on earth the third party program can extract this data? The MMORPG is not ...

Hooking thread creation/termination

Is it possible to hook into thread termination on Windows? IOW, I would like to be notified if a thread inside the process (not interested in other processes and their threads) has terminated (either normally or - more important - forcefully). Alternatively, hooking into thread creation would also do. Rationale: I have a library that m...

need to pipe between menu items in drupal (non-css)

Hi, (Newbie) How can I locate the PHP code which generates html for the menu in drupal 6? Is there a hook that I could customize? I wish to add pipe symbol between the items. I can add this using CSS but that is not what I want. Please suggest. Thanks, Vikas ...

SetWindowsHookEx, CBTProc and g++3.4.5 (mingw)

Hi, I'm currently working on an application that needs to add a menu to each application's system menu. I can accomplish that for the existing windows with the EnumWindows function. For the new windows (applications starting up after mine) I'm trying to do this with windows hooks. More specifically with CBTProc. This is where I'm stuck....

how to restart a mouse hook?

I have a mouse hook that (for an unknown reason) dies every now and then (not too often). Maybe it's because a mouse move is not processed fast enough by the hook at some point in time or smth. (can someone btw. tell me what the registry key is for the timeout value on Windows 7?), but whatever the reason, I'd like to know how I can rest...

Boost Intrusive List hook

What is the difference in a base hook and a member hook in Boost::Intrusive library and when is one better to use then the other? I've read the boost documentation, but its not that explanatory. ...

How do I write my hgrc so that Mercurial detects my hooks?

've written two functions in a file commit_hooks.py that I want to run before any commit is made persistent, but I can't figure out how to write my hgrc to detect them. The function headers are: def precommit_bad_merge(ui, repo, parent1=None, parent2=None, **kwargs): ... def precommit_bad_branching(ui, repo, **kwargs): ... I've trie...

White labeling CakePHP: What's the best way to provide customization hooks/callbacks to implementers?

I'm developing a CakePHP application that we will provide as a white label for people to implement for their own companies, and they'll need to have certain customization capabilities for themselves. For starters, they'll be able to do anything they want with the views, and they can add their own Controllers/Models if they need to add c...

LowLevelMouseProc in background thread

I'm trying to setup mouse hook on background thread. delegate IntPtr LowLevelMouseProc(int nCode, IntPtr wParam, IntPtr lParam); LowLevelMouseProc _proc = HookCallback; SetWindowsHookEx(PInvoke.WH_MOUSE_LL, _proc, IntPtr.Zero, 0); and IntPtr HookCallback(int nCode, IntPtr wParam, IntPtr lParam){/**/} If I put this on the main windo...

Using wxWidgets docking facilities from Mono (Linux)

In an attempt to port Inlage to Linux, one major problem is to support docking. Docking is done using Windows hooks from C#. Docking is not impossible as it was exhibited by Eclipse (the IDE) and also by wxWidgets (wxAUI video: www.kirix.com/labs/wxaui.html). The questions is, is it possible to easily port the C#-based (windows hooks-b...

How do I enable automatic email for SVN post-commits for a SVN+SSH repo in the local network?

We have a server whose SVN repos are accessible either via SVN+SSH or SAMBA. I already created: a shell script to send email (it works when executed by itself), a shell script based on the post-commit.tmpl in <repo path>/hooks/ which I named post-commit (executable by all) I even added a touch command within each script just so I can...

Combine files on commit in Mercurial

I've got a project with 2 files I want to source-control using Mercurial: A SCX-File which is a binary (database) file A SCT-File which is a text file My filter: [encode] **.scx = tempfile: sccxml INFILE OUTFILE 0 [decode] **.scx = tempfile: sccxml INFILE OUTFILE 1 Problem sccxml only receives the path to the SCX-File The SCX-Fi...

Did MS change something about keyboard hooks in Windows Vista or 7?

I've implemented keyboard hooks in several languages (AutoIt, C#) using SetWindowsHookEx and WH_KEYBOARD_LL. I also know of a couple of C++ programs that have the same issue. I didn't post any code because they work perfectly in Windows XP. However, under Windows 7, at some point the hooks become "unloaded" or stop processing any furt...

Is there a hook available when creating a tag in Subversion?

I think the question explains it all, but let me explain what I want to do. I am playing around with the idea of whenever a tag is created in my repo, all the commit messages entered since the previous tag are entered into a wiki page. That way, people do not need access to the subversion server to see what commits were made for each t...

C# Hook Windows Processes to Check for Debugging Processes

I was wondering if there is a way I could hook the windows processes to check if any suspicious programs are running like (Wireshark, Fiddler, OllyDBG, etc). I want to hook the windows processes so it will close the client or pop-up a message in real time when it detects a unwanted process. If you guys can provide me with any links to ...

Can I write a Java loader class that will hook HTTP requests in the loaded class?

I have a class that I want to hook and redirect HTTP requests in. I also have a loader class already written, but all it does it replace the functions that contain the HTTP requests I want to change. Is there a way to hook HTTP requests in Java so that I can redirect them all more easily? Sort of like a proxy-wrapper. Clarification: The...

Drag and drop files/text to tray icon (C#, WindowsForms)

I'm trying allow drag and drop to the tray icon on my application. I know it's impossible to do this with the higher level C# WindowsForms API, since NotifyIcon doesn't support drag events. So with a little help of a more windows-experienced friend I set out to try this via Win32 API. The idea was registering a hook in the tray window ...

How can I override the close button to minimize instead for a specific application?

I would like to override the close button to minimize an application instead. Can I write such thing in C#? Or do I need to use C++? How do I write this kind of hook? Do I need a process running or would a driver/dll/service suffice? As far as I got researching I think I have to do something like this but I don't know how exactly: ...

Problems with 'cross process subclassing'

Two questions. 1) I understand this must be an expected outcome but maybe someone can tell me what I'm doing wrong; I'm trying to subclass all window classes in a global hook and it works except that I'm not able to close shop as I should and when the program initially registering the hook unregisters the hook and exits, subclassed appl...

How to combine standard content type with customized hook_access() ?

I am happy with the standard Page and Story content types. Still I need more control over the access control. I would like to write my own access control. I like the concept of the hook_access() for controlling access to the content types you build your self. Do I have a hook_access() available when I am using my content type? ...